Reply to Re: [PHP] Newbie Help

Your name:

Reply:


Posted by Mark Cain on 05/02/05 07:36

Also, after I looked at more of your code you will need to specify the php
extension in only one of two places. Currently you are specifying it in 1)
the code below and in 2) nav.php and in nav.php you don't have it specified
for the "main" but you do for the other links. That means that the code
supplies the .php extension for main (which it needs to because it is simply
"main" and not "main.php") but the other pages are specified as "name.ext"
with the .php. Then when that page name gets to the script, the script is
adding .php onto the variable -- resulting in main.php, links/index.php.php,
email/email.php.php and so forth.

Do it one place or the other -- but do it consistently.

Looks like you're close to getting it to work and I'm close to going to bed.

Mark Cain



> >>The code that I'm trying to do this is the following:
> >><?php
> >> if(isset($_GET ['page']))
> >> {include($_GET ['page'].".php");}
> >> else
> >> {echo("Page Not Set.");}
> >>?>
> >>
> >>My site is: http://bonhamlinux.org
> >>My email is: freeswimfreak@yahoo.com
> >>
> >>Thanks for all the help.
> >>Thomas
> >>
> >>--
> >>PHP General Mailing List (http://www.php.net/)
> >>To unsubscribe, visit: http://www.php.net/unsub.php
> >>
> >>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация