|
#1
|
|||
|
|||
|
format <BROWSE_CATEGORIES>
Hi!
As I wanted to format this item to an "open listbox", I had to do the following changes: a) index.php: Code:
// build browse menu
// Get number of categories in database
$categorienumb = mysql_query("select count(*) as count from ".$pixelpost_db_prefix."categories");
$rowcat = mysql_fetch_array($categorienumb);
$categorienumb = $rowcat['count']+1;
$browse_select = "<select size='$categorienumb' name='browse' onChange='self.location.href=this.options[this.selectedIndex].value;'><option value='?x=browse&amp;category='>$lang_CatAll</option>";
$query = mysql_query("select * from ".$pixelpost_db_prefix."categories order by name");
while(list($id,$name) = mysql_fetch_row($query)) {
$name = pullout($name);
$browse_select .= "<option value='?x=browse&amp;category=$id'>$name</option>";
}
$browse_select .= "</select>";
Code:
$lang_CatAll = "alle Bilder"; Code:
Kategorien: <form><BROWSE_CATEGORIES></form> http://www.photografitti.de/pp/index...&category= Connie |
|
#2
|
||||
|
||||
|
very cool...
__________________
i should say more clever stuff |
| Post Reply |
| Thread Tools | |
|
|