Code: Select all
$value = $_GET['type'];
switch($value) {
case $HTTP_GET_VARS['type']:
$name = $row_List["name"];
$streetnumber = $row_List["streetnumber"];
$address = $row_List["address"];
$smalldesc = $row_List["smalldescription"];
$location = $row_List["location"];
$icons = $row_List["icons"];
$pic = $row_List["smallpic"];
$type = $row_List["type"];
break;
?>that works perfect, but now i want to add a $_GET['name'] because im also using this page as a search results page. Here is what i mean (the syntax is off though)
Code: Select all
$value = $_GET['type'] AND $value = $_GET['name']
switch($value) {
case $HTTP_GET_VARS['type']:
$name = $row_List["name"];
$streetnumber = $row_List["streetnumber"];
$address = $row_List["address"];
$smalldesc = $row_List["smalldescription"];
$location = $row_List["location"];
$icons = $row_List["icons"];
$pic = $row_List["smallpic"];
$type = $row_List["type"];
break;
case $HTTP_GET_VARS['type'] AND $HTTP_GET_VARS['name']:
$name = $row_List["name"];
$streetnumber = $row_List["streetnumber"];
$address = $row_List["address"];
$smalldesc = $row_List["smalldescription"];
$location = $row_List["location"];
$icons = $row_List["icons"];
$pic = $row_List["smallpic"];
$type = $row_List["type"];
break;
}
?>so how do i structure this? can i have everything in one "switch statement" or do i need more than one?
thanx