views:

55

answers:

2

I have downloaded a backup copy of my cpanel webserver. I install WAMP on my local laptop.The database and php username and password have been set. Then I loaded the database into the local MySQL database. I verified the phpinfo.php is working. I setup dreamweaver manage site with the extracted website on my laptop. Now the back end admin pages on my laptop for my website are working. However the frontend is not completely loading and I can't figure out why.

Please go here to see what the page looks like since I can't post images on this post. dev.quicksalenetwork.com/images/frontend.png

Now if you go to the live development site you would see what is should look like.

Also here is the source code of the index.php page.

<?php 
//redirect for install
if(!file_exists('Connections/myconn.php'))
 header('Location:install.php');

//install file check
/*if(file_exists('install.php') || file_exists('install2.php') || file_exists('install3.php'))
 print '<font color="red"><strong>Please delete install files { install.php , install1.php, install2.php }</strong></font><br>';
*/

//*******************************************************************************
//PHP Real Estate Classifieds
//All Rights reserved by Quick Sale Network inc.
//Do not modify, duplicate, resell with out direct permission from Quick Sale Network inc.
//Script is bound by terms listed in terms.html file
//*******************************************************************************




//fetch template header 
include('header.php');

//define varable 
define('go','');
//set index varable for switch statment
if (isset($_REQUEST['go']))
 $go = $_REQUEST['go']; // requested page 
else
 $go = ''; // default

switch($go) {
 case 'gmap':
  include('gmap.php');
  break;
 case 'photos':
  include('photos.php');
  break;
 case 'resource_center':
  include('resource_center.php');
  break;
 case 'linkdir':
  include('linkdir.php');
  break;
 case 'mailme':
  include('formmail.php');
  break;
 case 'sell':
  include('sell.php');
  break;
 case 'buy':
  include('buy.php');
  break;
 case 'properties':
  include('properties.php');
  break;
 case 'login' :
  header("location: members/login.php");
  break;
 case 'register' :
  include('register.php');
  break;
 case 'pricing' :
  include('pricing.php');
  break;
 case 'calc' :
  include('calc.php');
  break;
 case 'contact' :
  include('contact.php');
  break;
 case 'faq' :
  include('faq.php');
  break;
 case 'features' : 
  include('features.php');
  break;
 case 'member_login' :
  include('member_login.php');
  break;
 case 'mailme' :
  echo"<br><h4>";
  include('formmail.php');
  echo"</h4>";
  break;
 case 'detail' :
  include('detail.php');
  break;
 case 'search' :
  include('search.php');
  break;
 /*case 'home_gmap' :
  include('home.php');*/
 default:
  include('home_gmap.php');
  break;
}//end of switch statment


//fetch template footer
include('footer_city.php');

?>

Any ideas what I am doing wrong?

A: 

I had the same thing happen to me. It happens when a file is corrupted. Just delete the file (Blanking it wont work) and copy all the code back into it.

Colum
+1  A: 

My guess:

your code uses php short open tags (<? instead of <?php) and you haven't enabled short tags in your wamp install..

There's a short_open_tag directive in your php.ini to enable it

Ben
+1 Check the rendered HTML source for `<?`
Phil Brown
@Phil. Good thinking.
Ben