Help - Search - Members - Calendar
Full Version: Pages Not Working...
Zymic Webmaster Forums > Web Design & Development > Client Side Scripting > JavaScript
bekdesignsdotcom
Hello,

We have a PHP Include on one of the sites we did for a client. It's been working awesome for a good month, today I tried to add a new page and when you go to the page it's blank!

The page I created is: http://toledohba.com/index.php?act=designservices3
Which when you go to it, it's completely blank even though I clearly did put words on it. I duplicated it from another page on the site, so I know I copied all of the code right.

The script is:

CODE
<?PHP
error_reporting(0);
$pages = array( 'home'=> './index.php',

'home'=> './home.php',
'foundation'=> './foundation.php',
'officers'=> './officers.php',
'ethics'=> './ethics.php',
'missionstatement'=> './missionstatement.php',
'committees_councils'=> './committees_councils.php',
'directory'=> './directory.php',
'contactus'=> './contactus.php',
'thelevel'=> './thelevel.php',
'staff'=> './staff.php',
'benefits'=> './benefits.php',
'committeescouncils'=> './committeescouncils.php',
'grievance_ethics'=> './grievance_ethics.php',
'builderfaq'=> './builderfaq.php',
'samawards'=> './samawards.php',
'other_events'=> './other_events.php',
'paradeofhomes'=> './paradeofhomes.php',
'hbanews'=> './hbanews.php',
'designservices2'=> './designservices2.php',
'designservices3'=> './designservices3.php',
'permitreport'=> './permitreport.php',
'mortgagebasics'=> './mortgagebasics.php',
'designservices'=> './designservices.php',
'buildpac'=> './buildpac.php',
'seminars'=> './seminars.php',
'certifications'=> './certifications.php',
'builders'=> './builders.php',
'suppliers'=> './suppliers.php',
'greeninfo'=> './greeninfo.php',
'members'=> './members.php',
'calendar'=> './calendar.php',
'industrynews'=> './industrynews.php',
'warranties'=> './warranties.php',
'testlogin'=> './testlogin.php',
'helpfullinks'=> './helpfullinks.php',
'application'=> './application.php',
'hbalogo'=> './hbalogo.php',
'marketing'=> './marketing.php',
'benefitsofmembership'=> './benefitsofmembership.php',
'classifieds'=> './classifieds.php',
'helpwanted'=> './helpwanted.php',
'forsale'=> './forsale.php',
'whatshappening'=> './whatshappening.php',
'articles'=> './articles.php',
'housekeys'=> './housekeys.php',
'househomeshow'=> './househomeshow.php',
'login' => './uPanel/index.php',
'upanel' => './uPanel/home.php',
'signin' => './uPanel/login.php',
'logout' => './uPanel/logout.php',
'save' => './uPanel/member.php',
'addcustomer' => './uPanel/home.php',
'editcustomers' => './uPanel/home.php',
'editcustomer' => './uPanel/home.php',
'savecustomer' => './uPanel/home.php',
'search' => './uPanel/home.php',
'addadmin' => './uPanel/home.php',
'admin' => './uPanel/home.php',
'editadmin' => './uPanel/home.php',
'restricted' => './restricted.php');

$act = $_GET[ 'act' ];
if( ! isset( $pages[ $act ] ) ) {
$act = 'home';
} include( $pages[ $act ] );
?>


Any idea's @ all would def help!

Thanks,

Eric
Ed
Best thing to do would be to show the errors with :

CODE
error_reporting(E_ALL);
ini_set('display_errors', true);


With the errors hidden it could be any number of things, my guess is a parse error in the 'designservices3.php' page.
bekdesignsdotcom
Hello,

Somehow the page just decided to show up today. I did turn errors on like you suggested and it's saying this:



Notice: Undefined index: act in /var/www/vhosts/toledohba.com/httpdocs/index.php on line 187


Cept, I dont see any kind of error on line 187. This is line 187:

$act = $_GET[ 'act' ];


Any idea's?

-Eric
bekdesignsdotcom
Oh to your response of how the designservices page might be layed out...


CODE
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Home Builders Association of Greater Toledo</title>
<meta name="description" content="Home Builders Association of Greater Toledo" />
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="content.css" type="text/css" rel="stylesheet" />
</head>
<body bgcolor="#eeeeee">
<!-- Begin Thumbnail Table -->
<p align="left">
<table border="0" cellspacing="3" cellpadding="3">
<tr>
<td valign="top" style="padding:10px 10px 10px 10px;">

<font color="black" size="2" face="tahoma"><b>

Every package below, comes with a totally custom website design. That means, you have idea's for a website, we will make it happen! No design is ever same for someone else! Pick a package or questions please call us today at 419-344-2836! We will be happy to help you!</b></font><BR>
<img src="images/designpackages.png">
</center>
</td></tr></table>
<!-- End Thumbnail Table -->
</body>
</html>
</html>


Thats the page... pretty straight forward I think.

-Eric
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2012 Invision Power Services, Inc.