Log In · Register

 
dynamic inclusions, inclsuion errors
synatribe
post May 6 2008, 07:54 PM
Post #1


AIDS at RAVES.
******

Group: Official Designer
Posts: 2,386
Joined: Dec 2007
Member No: 598,878



okay so Im currently using dynamic inclusion for my site however, everything works fine except for the index page,
QUOTE
Warning: include() [function.include]: Failed opening '' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/kevinjo/public_html/colourfierce/index.php on line 83


that comes up on my index,
and this is all the php, I have on my site index
QUOTE
<?php
$page = $_GET['page'];
$pages = array('page1', 'page2', 'page3');
if (!empty($page)) {
if(in_array($page,$pages)) {
$page .= '.php';
include($page);
}
else {
echo '';
}
}
else {
include('page1.php');
}
?>

<?php
$url = '';
if (!empty($_GET['category'])) {
$url .= $_GET['category'] . '/';
}
if (!empty($_GET['page'])) {
$url .= $_GET['page'] . '.php';
}
include $url;
?>


now this is what I have on line 83
QUOTE
include $url;


. I tried to figure it out but with no avail, any help? thanks in advance :]
 

Posts in this topic
SkyliteX   dynamic inclusions   May 6 2008, 07:54 PM
SkyliteX   sorry to bump this but if someone knows the answer...   May 6 2008, 09:20 PM


Closed TopicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members: