diff options
-rw-r--r-- | admin/catalog.php | 111 | ||||
-rw-r--r-- | lib/class/catalog.class.php | 84 | ||||
-rw-r--r-- | lib/ui.lib.php | 2 | ||||
-rw-r--r-- | templates/basestyle.inc.php (renamed from templates/menustyle.inc) | 13 | ||||
-rw-r--r-- | templates/header.inc | 3 | ||||
-rw-r--r-- | templates/show_admin_catalog.inc.php | 21 | ||||
-rw-r--r-- | templates/show_confirmation.inc.php | 4 | ||||
-rw-r--r-- | templates/style.inc | 13 |
8 files changed, 161 insertions, 90 deletions
diff --git a/admin/catalog.php b/admin/catalog.php index ef5708ba..0f79a1ce 100644 --- a/admin/catalog.php +++ b/admin/catalog.php @@ -45,16 +45,22 @@ switch ($_REQUEST['action']) { $type = 'show_flagged_songs'; include(conf('prefix') . '/templates/flag.inc'); break; - case _("Add to Catalog(s)"): + case 'add_to_all_catalogs': + $_REQUEST['catalogs'] = Catalog::get_catalog_ids(); case 'add_to_catalog': if (conf('demo_mode')) { break; } if ($_REQUEST['catalogs'] ) { foreach ($_REQUEST['catalogs'] as $catalog_id) { + echo "<div class=\"confirmation-box\">"; $catalog = new Catalog($catalog_id); $catalog->add_to_catalog($_REQUEST['update_type']); + echo "</div>"; } } - include(conf('prefix') . '/templates/catalog.inc'); + $url = conf('web_path') . '/admin/index.php'; + $title = _('Catalog Updated'); + $body = ''; + show_confirmation($title,$body,$url); break; case _("Add to all Catalogs"): if (conf('demo_mode')) { break; } @@ -78,49 +84,43 @@ switch ($_REQUEST['action']) { } include(conf('prefix') . '/templates/catalog.inc'); break; - case _("Update Catalog(s)"): + case 'update_all_catalogs': + $_REQUEST['catalogs'] = Catalog::get_catalog_ids(); case 'update_catalog': /* If they are in demo mode stop here */ if (conf('demo_mode')) { break; } if (isset($_REQUEST['catalogs'])) { foreach ($_REQUEST['catalogs'] as $catalog_id) { + echo "<div class=\"confirmation-box\">"; $catalog = new Catalog($catalog_id); $catalog->verify_catalog($catalog_id->id,$_REQUEST['update_type']); + echo "</div>\n"; } } - include(conf('prefix') . '/templates/catalog.inc'); - break; - case _("Update All Catalogs"): - if (conf('demo_mode')) { break; } - $catalogs = $catalog->get_catalogs(); - - foreach ($catalogs as $data) { - $data->verify_catalog($data->id,$_REQUEST['update_type']); - } - include(conf('prefix') . '/templates/catalog.inc'); + $url = conf('web_path') . '/admin/index.php'; + $title = _('Catalog Updated'); + $body = ''; + show_confirmation($title,$body,$url); break; case 'full_service': /* Make sure they aren't in demo mode */ if (conf('demo_mode')) { break; } if (!$_REQUEST['catalogs']) { - $_REQUEST['catalogs'] = array(); - $catalogs = Catalog::get_catalogs(); + $_REQUEST['catalogs'] = Catalog::get_catalog_ids(); } /* This runs the clean/verify/add in that order */ foreach ($_REQUEST['catalogs'] as $catalog_id) { + echo "<div class=\"confirmation-box\">"; $catalog = new Catalog($catalog_id); - $catalogs[] = $catalog; - } - - foreach ($catalogs as $catalog) { $catalog->clean_catalog(); $catalog->count = 0; $catalog->verify_catalog(); $catalog->count = 0; $catalog->add_to_catalog(); + echo "</div>"; } break; case 'delete_catalog': @@ -145,7 +145,8 @@ switch ($_REQUEST['action']) { } include(conf('prefix') . '/templates/catalog.inc'); break; - case _('Clean Catalog(s)'): + case 'clean_all_catalogs': + $_REQUEST['catalogs'] = Catalog::get_catalog_ids(); case 'clean_catalog': /* If they are in demo mode stop them here */ if (conf('demo_mode')) { break; } @@ -153,39 +154,29 @@ switch ($_REQUEST['action']) { // Make sure they checked something if (isset($_REQUEST['catalogs'])) { foreach($_REQUEST['catalogs'] as $catalog_id) { + echo "<div class=\"confirmation-box\">"; $catalog = new Catalog($catalog_id); $catalog->clean_catalog(0,1); + echo "</div>"; } // end foreach catalogs } - include(conf('prefix') . '/templates/catalog.inc'); + + $url = conf('web_path') . '/admin/index.php'; + $title = _('Catalog Cleaned'); + $body = ''; + show_confirmation($title,$body,$url); break; case 'update_catalog_settings': + /* No Demo Here! */ if (conf('demo_mode')) { break; } - $id = strip_tags($_REQUEST['catalog_id']); - $name = strip_tags($_REQUEST['name']); - $id3cmd = strip_tags($_REQUEST['id3_set_command']); - $rename = strip_tags($_REQUEST['rename_pattern']); - $sort = strip_tags($_REQUEST['sort_pattern']); - /* Setup SQL */ - $sql = "UPDATE catalog SET " . - " name = '$name'," . - " id3_set_command = '$id3cmd'," . - " rename_pattern = '$rename'," . - " sort_pattern = '$sort'" . - " WHERE id = '$id'"; - $result = mysql_query($sql, dbh()); - include(conf('prefix') . '/templates/catalog.inc'); - break; - case _("Clean All Catalogs"): - if (conf('demo_mode')) { break; } - $catalogs = $catalog->get_catalogs(); - $dead_files = array(); - - foreach ($catalogs as $catalog) { - $catalog->clean_catalog(0,$_REQUEST['update_type']); - } - - include(conf('prefix') . '/templates/catalog.inc'); + + /* Update the catalog */ + Catalog::update_settings($_REQUEST); + + $url = conf('web_path') . '/admin/index.php'; + $title = _('Catalog Updated'); + $body = ''; + show_confirmation($title,$body,$url); break; // FIXME! case 'add_catalog': @@ -195,6 +186,10 @@ switch ($_REQUEST['action']) { if ($_REQUEST['path'] AND $_REQUEST['name']) { /* Throw all of the album art types into an array */ $art = array('id3'=>$_REQUEST['art_id3v2'],'amazon'=>$_REQUEST['art_amazon'],'folder'=>$_REQUEST['art_folder']); + + /* Enclose it in a purrty box! */ + echo "<div class=\"confirmation-box\">"; + /* Create the Catalog */ $catalog->new_catalog($_REQUEST['path'], $_REQUEST['name'], @@ -205,6 +200,9 @@ switch ($_REQUEST['action']) { $_REQUEST['gather_art'], $_REQUEST['parse_m3u'], $art); + + echo "</div>\n"; + $url = conf('web_path') . '/admin/index.php'; $title = _('Catalog Created'); $body = _('Catalog Created and Songs Indexed'); @@ -243,12 +241,13 @@ switch ($_REQUEST['action']) { break; case 'show_disabled': if (conf('demo_mode')) { break; } + $songs = $catalog->get_disabled(); if (count($songs)) { require (conf('prefix') . '/templates/show_disabled_songs.inc'); } else { - echo "<p class=\"error\" align=\"center\">No Disabled songs found</p>"; + echo "<div class=\"error\" align=\"center\">No Disabled songs found</div>"; } break; case 'show_delete_catalog': @@ -258,28 +257,26 @@ switch ($_REQUEST['action']) { $nexturl = conf('web_path') . '/admin/catalog.php?action=delete_catalog&catalog_id=' . scrub_out($_REQUEST['catalog_id']); show_confirmation(_('Delete Catalog'),_('Do you really want to delete this catalog?'),$nexturl,1); break; - case 'show_flagged_songs': - if (conf('demo_mode')) { break; } - $type = $_REQUEST['action']; - include (conf('prefix') . '/templates/flag.inc'); - break; case 'show_customize_catalog': include(conf('prefix') . '/templates/customize_catalog.inc'); break; case 'gather_album_art': - echo "<b>" . _("Starting Album Art Search") . ". . .</b><br /><br />\n"; flush(); $catalogs = $catalog->get_catalogs(); foreach ($catalogs as $data) { + echo "<div class=\"confirmation-box\"><b>" . _("Starting Album Art Search") . ". . .</b><br /><br />\n"; + echo _('Searched') . ": <span id=\"count_art_" . $data->id . "\">" . _('None') . "</span><br />"; $data->get_album_art(); + echo "<b>" . _("Album Art Search Finished") . ". . .</b></div>\n"; } - - echo "<b>" . _("Album Art Search Finished") . ". . .</b><br />\n"; - + $url = conf('web_path') . '/admin/index.php'; + $title = _('Album Art Search Finished'); + $body = ''; + show_confirmation($title,$body,$url); break; default: - include(conf('prefix') . '/templates/catalog.inc'); + /* Not sure what to put here anymore */ break; } // end switch diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php index fc78971d..171e7745 100644 --- a/lib/class/catalog.class.php +++ b/lib/class/catalog.class.php @@ -107,6 +107,22 @@ class Catalog { } // get_catalogs + /** + * get_catalog_ids + * This returns an array of all catalog ids + */ + function get_catalog_ids() { + + $sql = "SELECT id FROM catalog"; + $db_results = mysql_query($sql, dbh()); + + while ($r = mysql_fetch_assoc($db_results)) { + $results[] = $r['id']; + } + + return $results; + + } // get_catalog_ids /*! @function get_catalog_stats @@ -382,7 +398,7 @@ class Catalog { $this->count++; if ( !($this->count%conf('catalog_echo_count')) ) { echo "<script language=\"JavaScript\">"; - echo "update_txt('" . $this->count . "','count');"; + echo "update_txt('" . $this->count . "','count_add_" . $this->id ."');"; echo "</script>\n"; flush(); } //echos song count @@ -474,7 +490,9 @@ class Catalog { /* Stupid little cutesie thing */ $search_count++; if ( !($search_count%conf('catalog_echo_count')) ) { - echo _("Searched") . " $search_count. . . . <br />\n"; + echo "<script language=\"JavaScript\">"; + echo "update_txt('" . $search_count ."','count_art_" . $this->id . "');"; + echo "</script>\n"; flush(); } //echos song count @@ -701,6 +719,25 @@ class Catalog { } // update_last_add + /** + * update_settings + * This function updates the basic setting of the catalog + */ + function update_settings($data) { + + $id = sql_escape($data['catalog_id']); + $name = sql_escape($data['name']); + $id3cmd = sql_escape($data['id3cmd']); + $rename = sql_escape($data['rename_pattern']); + $sort = sql_escape($data['sort_pattern']); + + $sql = "UPDATE catalog SET name='$name', id3_set_command='$id3cmd', rename_pattern='$rename', " . + "sort_pattern='$sort' WHERE id = '$id'"; + $db_results = mysql_query($sql, dbh()); + + return true; + + } // update_settings /** * new_catalog @@ -764,6 +801,7 @@ class Catalog { /* Now Adding Album Art? */ if ($gather_art) { echo "<br />\n<b>" . _("Starting Album Art Search") . ". . .</b><br />\n"; + echo _('Searched') . ": <span id=\"count_art_" . $this->id . "\">" . _('None') . "</span>"; flush(); $this->get_album_art(0,$art); } // if we want to gather album art @@ -906,7 +944,7 @@ class Catalog { return true; } - echo _('Found') . ": <span id=\"count\">" . _('None') . "</span><br />\n"; + echo _('Found') . ": <span id=\"count_add_" . $this->id ."\">" . _('None') . "</span><br />\n"; flush(); /* Set the Start time */ @@ -931,6 +969,7 @@ class Catalog { if ($type != 'fast_add') { if ($verbose) { echo "\n<b>" . _('Starting Album Art Search') . ". . .</b><br />\n"; + echo _('Searched') . ": <span id=\"count_art_" . $this->id . "\">" . _('None') . "</span>"; flush(); } $this->get_album_art(); @@ -1139,7 +1178,7 @@ class Catalog { if ($verbose) { echo "\n" . _('Cleaning the') . " <b>[" . $this->name . "]</b> " . _('Catalog') . "...<br />\n"; - echo _('Checking') . ": <span id=\"count\"></span>\n<br />"; + echo _('Checking') . ": <span id=\"count_clean_" . $this->id . "\"></span>\n<br />"; flush(); } @@ -1157,7 +1196,7 @@ class Catalog { $this->count++; if ( !($this->count%conf('catalog_echo_count')) && $verbose) { echo "<script language=\"JavaScript\">"; - echo "update_txt('" . $this->count ."','count');"; + echo "update_txt('" . $this->count ."','count_clean_" . $this->id . "');"; echo "</script>\n"; flush(); } //echos song count @@ -1485,7 +1524,7 @@ class Catalog { if ($verbose) { echo _("Updating the") . " <b>[ $this->name ]</b> " . _("Catalog") . "<br />\n"; echo $number . " " . _("songs found checking tag information.") . "<br />\n\n"; - echo _('Verifed') . ": <span=\"count\">None</span><br />\n"; + echo _('Verifed') . ": <span id=\"count_verify_" . $this->id . "\">None</span><br />\n"; flush(); } @@ -1502,7 +1541,7 @@ class Catalog { /* Create the object from the existing database information */ $song = new Song($results->id); - if (conf('debug')) { log_event($_SESSION['userdata']['username'],' verify ',"Starting work on $song->file",'ampache-catalog'); } + debug_event('verify',"Starting work on $song->file",'5','ampache-catalog'); if (is_readable($song->file)) { unset($skip); @@ -1537,11 +1576,11 @@ class Catalog { $found = $album->get_art(); unset($album); if ($found) { $is_found = _(" FOUND"); } - echo "<br /><b>" . _("Searching for new Album Art") . ". . .$is_found</b><br />\n"; + echo "<br /><b>" . _('Searching for new Album Art') . ". . .$is_found</b><br />\n"; unset($found,$is_found); } elseif (isset($searched_albums[$album_id])) { - echo "<br /><b>" . _("Album Art Already Found") . ". . .</b><br />\n"; + echo "<br /><b>" . _('Album Art Already Found') . ". . .</b><br />\n"; } echo "\t</li>\n</dl>\n<hr align=\"left\" width=\"50%\" />\n"; flush(); @@ -1553,14 +1592,14 @@ class Catalog { } // end skip if ($skip) { - if (conf('debug')) { log_event($_SESSION['userdata']['username'],' skip ',"$song->file has been skipped due to newer local update or file mod time",'ampache-catalog'); } + debug_event('skip',"$song->file has been skipped due to newer local update or file mod time",'5','ampache-catalog'); } /* Stupid little cutesie thing */ $this->count++; - if ( !($this->count%conf('catalog_echo_count')) ) { + if (!($this->count%conf('catalog_echo_count')) ) { echo "<script language=\"JavaScript\">"; - echo "update_txt('" . $this->count . "','count');"; + echo "update_txt('" . $this->count . "','count_verify_" . $this->id . "');"; echo "</script>\n"; flush(); } //echos song count @@ -1570,17 +1609,13 @@ class Catalog { else { echo "<dl>\n <li>"; echo "<b>$song->file does not exist or is not readable</b>\n"; - echo " </li>\n</dl>\n<hr align=\"left\" width=\"50%\" />\n"; - - if (conf('debug')) { log_event($_SESSION['userdata']['username'],' read-error ',"$song->file does not exist or is not readable",'ampache-catalog'); } + echo "</li>\n</dl>\n<hr align=\"left\" width=\"50%\" />\n"; - // Should we remove it from catalog? + debug_event('read-error',"$song->file does not exist or is not readable",'5','ampache-catalog'); } - } //end foreach - /* After we have updated all the songs with the new information clear any empty albums/artists */ $this->clean_albums(); $this->clean_artists(); @@ -1590,7 +1625,7 @@ class Catalog { // Update the last_update $this->update_last_update(); - echo "Update Finished. Checked $this->count. $total_updated songs updated.<br /><br />"; + echo _('Update Finished.') . _('Checked') . " $this->count. $total_updated " . _('songs updated.') . "<br /><br />"; $this->count = 0; @@ -1717,7 +1752,7 @@ class Catalog { if ($artist_count == $cache_limit) { $this->artists = array_slice($this->artists,1); } - if (conf('debug')) { log_event($_SESSION['userdata']['username'],'cache',"Adding $artist with $artist_id to Cache",'ampache-catalog'); } + debug_event('cache',"Adding $artist with $artist_id to Cache",'5','ampache-catalog'); $array = array($artist => $artist_id); $this->artists = array_merge($this->artists, $array); unset($array); @@ -1919,7 +1954,7 @@ class Catalog { $db_results = mysql_query($sql, dbh()); if (!$db_results) { - if (conf('debug')) { log_event($_SESSION['userdata']['username'],'insert',"Unable to insert $file -- $sql",'ampache-catalog'); } + debug_event('insert',"Unable to insert $file -- $sql",'5','ampache-catalog'); echo "<span style=\"color: #F00;\">Error Adding $file </span><br />$sql<br />"; flush(); } @@ -1948,7 +1983,7 @@ class Catalog { $db_results = mysql_query($sql, dbh()); if (!$db_results) { - if (conf('debug')) { log_event($_SESSION['userdata']['username'],'insert',"Unable to Add Remote $url -- $sql",'ampache-catalog'); } + debug_event('insert',"Unable to Add Remote $url -- $sql",'5','ampache-catalog'); echo "<span style=\"color: #FOO;\">Error Adding Remote $url </span><br />$sql<br />\n"; flush(); } @@ -1998,7 +2033,7 @@ class Catalog { $db_results = mysql_query($sql, dbh()); //If it's found then return true - if (@mysql_fetch_row($db_results)) { + if (mysql_fetch_row($db_results)) { return true; } @@ -2035,7 +2070,7 @@ class Catalog { } // end foreach line - if (conf('debug')) { log_event($GLOBALS['user']->username,'m3u_parse',"Parsing $filename - Found: " . count($songs) . " Songs"); } + debug_event('m3u_parse',"Parsing $filename - Found: " . count($songs) . " Songs",'5'); if (count($songs)) { $playlist = new Playlist(); @@ -2143,6 +2178,7 @@ class Catalog { $this->clean_stats(); $this->clean_playlists(); $this->clean_flagged(); + $this->clean_genre(); } // delete_catalog diff --git a/lib/ui.lib.php b/lib/ui.lib.php index fc200ee7..dec697ae 100644 --- a/lib/ui.lib.php +++ b/lib/ui.lib.php @@ -272,7 +272,7 @@ function return_referer() { /* Strip off the filename */ $referer = substr($referer,0,strlen($referer)-strlen($file)); - + if (substr($referer,strlen($referer)-6,6) == 'admin/') { $file = 'admin/' . $file; } diff --git a/templates/menustyle.inc b/templates/basestyle.inc.php index c922ce6e..d33ab9f5 100644 --- a/templates/menustyle.inc +++ b/templates/basestyle.inc.php @@ -248,5 +248,18 @@ border-color: <?php echo conf('bg_color2'); ?>; border-bottom: 1px solid <?php echo conf('bg_color2'); ?>; } +/* Other Required Styles */ + .confirmation-box { + padding-left:5px; + padding-top:5px; + padding-right:5px; + margin-bottom:10px; + width:40em; + background-color: <?php echo conf('base_color1'); ?>; + border-right:2px solid <?php echo conf('bg_color2'); ?>; + border-bottom:2px solid <?php echo conf('bg_color2'); ?>; + border-left:2px solid <?php echo conf('bg_color2'); ?>; + border-top:2px solid <?php echo conf('bg_color2'); ?>; + } --> </style> diff --git a/templates/header.inc b/templates/header.inc index f1a2b8ed..1277c4bc 100644 --- a/templates/header.inc +++ b/templates/header.inc @@ -33,10 +33,9 @@ if (conf('use_rss')) { ?> <link rel="alternate" type="application/rss+xml" title="<?php echo conf('rss_main_title'); ?>" href="<?php echo $web_path; ?>/rss.php" /> <?php } ?> <meta http-equiv="Content-Type" content="text/html; charset=<?php echo conf('site_charset'); ?>" /> -<?php show_template('menustyle'); show_template('style'); ?> +<?php require (conf('prefix') . '/templates/basestyle.inc.php'); show_template('style'); ?> <title><?php echo conf('site_title'); ?> - <?php echo $location['title']; ?></title> </head> - <body> <script src="<?php echo $web_path; ?>/lib/general.js" language="javascript" type="text/javascript"></script> <div id="maincontainer"> diff --git a/templates/show_admin_catalog.inc.php b/templates/show_admin_catalog.inc.php index 73b9cb88..5db5f9ed 100644 --- a/templates/show_admin_catalog.inc.php +++ b/templates/show_admin_catalog.inc.php @@ -42,7 +42,7 @@ $catalogs = Catalog::get_catalogs(); <a href="<?php echo $web_path; ?>/admin/catalog.php?action=add_to_catalog&catalogs[]=<?php echo $catalog->id; ?>"> <?php echo _('Add'); ?></a> | <a href="<?php echo $web_path; ?>/admin/catalog.php?action=update_catalog&catalogs[]=<?php echo $catalog->id; ?>"> - <?php echo _('Update'); ?></a> | + <?php echo _('Verify'); ?></a> | <a href="<?php echo $web_path; ?>/admin/catalog.php?action=clean_catalog&catalogs[]=<?php echo $catalog->id; ?>"> <?php echo _('Clean'); ?></a> | <a href="<?php echo $web_path; ?>/admin/catalog.php?action=full_service&catalogs[]=<?php echo $catalog->id; ?>"> @@ -60,9 +60,22 @@ $catalogs = Catalog::get_catalogs(); </tr> <?php } // end if no catalogs ?> </table> -<form method="post" enctype="multipart/form-data" action="<?php echo $web_path; ?>/admin/catalog.php?action=full_service"> -<input class="button" type="submit" value="<?php echo _('Update Everything'); ?>" /> -</form> +<script type="text/javascript" language="javascript"> +<!-- +function ToCatalog(action) +{ + document.catalog.action = "<?php echo conf('web_path'); ?>/admin/catalog.php?action=" + action; + document.catalog.submit(); // Submit the page + return true; +} + +--> +</script> +<form name="catalog" method="post" enctype="multipart/form-data" style="Display:inline;"> +<input class="button" type="button" value="<?php echo _('Clean Everything'); ?>" onclick="return ToCatalog('clean_all_catalogs');" /> +<input class="button" type="button" value="<?php echo _('Verify Everything'); ?>" onclick="return ToCatalog('update_all_catalogs');" /> +<input class="button" type="button" value="<?php echo _('Add to Everything'); ?>" onclick="return ToCatalog('add_to_all_catalogs');" /> +<input class="button" type="button" value="<?php echo _('Update Everything'); ?>" onclick="return ToCatalog('full_service');" /> </div> <div class="text-box"> <span class="header2"><?php echo _('Other Tools'); ?></span><br /> diff --git a/templates/show_confirmation.inc.php b/templates/show_confirmation.inc.php index d561f137..07994401 100644 --- a/templates/show_confirmation.inc.php +++ b/templates/show_confirmation.inc.php @@ -19,12 +19,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ ?> -<div class="text-box" style="width:35em;"> +<div class="confirmation-box"> <span class="header1"><?php echo scrub_out($title); ?></span><br /> <?php echo scrub_out($text); ?> <br /><br /> [ <a href="<?php echo $path; ?>"><?php echo _('Continue'); ?></a> ] <?php if ($cancel) { ?> - [ <a href="<?php echo return_referer(); ?>"><?php echo _('Cancel'); ?></a> ]<br /> + [ <a href="<?php echo conf('web_path') . "/" . return_referer(); ?>"><?php echo _('Cancel'); ?></a> ]<br /> <?php } ?> </div> diff --git a/templates/style.inc b/templates/style.inc index bc55d541..984fe817 100644 --- a/templates/style.inc +++ b/templates/style.inc @@ -73,6 +73,19 @@ border-left:2px solid <?php echo conf('bg_color2'); ?>; border-top:2px solid <?php echo conf('bg_color2'); ?>; } + .confirmation-box + { + padding-left:5px; + padding-top:5px; + padding-right:5px; + margin-bottom:10px; + width:35em; + background-color: <?php echo conf('base_color1'); ?>; + border-right:2px solid <?php echo conf('bg_color2'); ?>; + border-bottom:2px solid <?php echo conf('bg_color2'); ?>; + border-left:2px solid <?php echo conf('bg_color2'); ?>; + border-top:2px solid <?php echo conf('bg_color2'); ?>; + } .selected_button { background-color: black;color:white; |