Re: How do you do the ? mark after a filename

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thomas Bonham schrieb:
I keep seeing the ? mark after many file names index.php?id=234.

So what I would like to know is how do you make them. I have heard that they can make a programs life sampler when doing somethings with a database.

in my scripts, i do it with the switch-syntax

=== snip ===
switch($_GET['x'])
{
        case "show": include("show.php"); break;
        case "search": include("search.php"); break;
        case "new": include("add_entry.html"); break;
        default: include("show.php"); break;
}
?>
=== snip ===

now you can enter http://www.domain.at/index.php?x=search; or x=show;





cu,
 norbert.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux