RE: [PHP] variables over 2 pages w/ a table.

From: Date: Wed, 01 May 2002 22:54:19 +0000
Subject: RE: [PHP] variables over 2 pages w/ a table.
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-95623@lists.php.net to get a copy of this message
> $left = "news"; > $ltitle = "index"; > $lext= "php"; > > include ("$left/$ltitle.$lext"); > > <a href=index.php?lext=php?start=8>next</a> > > so this should link to the index page, which calls upon > news/index.php, opens > it in the left column of the table, and gives $start the value of 8. > > but it gives me this error: > > Warning: Failed opening 'news/index.php?start=8' for inclusion > (include_path='') in /home/blindtheory/web/newweb/index.php on line 31 > > so how can i solve this and get the articles to show in groups of 8? Well your error message tells you your problem immediately. do you have a file named /home/blindtheory/web/newweb/news/index.php?start=8 ? I doubt you do =) You're trying to pass what would normally be an HTTP query string as a parameter for opening a local file on your system. There's an exact example of this on http://www.php.net/manual/en/function.include.php example 11-5. Basically you need the include to be an http link...not a local link ex. include("http://www.foobar.com/index.php?lext=php?start=8"); Sincerely, Craig Vincent

« previous php.general (#95623) next »