I'm using Windows XP. I've successfully set up MYSQL, restored the database and installed PHP and its extensions.

Our drupal site is located in a folder named htdocs. Yesterday, after attempting to install in my root folder I ended up deleting
it and replacing it again with the backup from the server.

I went into sites/default/settings.php and updated the database info. Next, checked out the settings in IIS and everything seems fine. So I tried running http://localhost/htdocs (index.php). A whole bunch of plain text appears, as if its not recognizing php. However, other php sites are working fine that are in my root directory. Here's a small example of what I'm seeing when
I try to run index.php:
'markup', '#value' => print_r($form)); /* Set destination as thank-you page. */ $form['#redirect'] = array('rfp-thank-you'); /* Get rid of "preview" button. */ unset($form['preview']); } return; } /** * Implementation of hook_menu(). */ function gwr_custom_menu($may_cache) { $items = array(); if ($may_cache) { /* This patches in the settings form to the admin * settings pages section... */ $items[] = array( 'path' => 'admin/settings/gwr_custom', 'title' => t('GWR Custom'), 'callback' => 'drupal_get_form', 'callback arguments' => array('gwr_custom_admin_settings'), 'access' => user_access('administer site configuration'), 'type' => MENU_NORMAL_ITEM, ); /* This page redirects based on the current session's location id. */ $items[] = array( 'path' => 'gwr/location/redirect', etc....

Does anyone know what's going on?

Thanks

Comments

lionheart8’s picture

I have not used IIS, so I dont know whether this applies. I normally use Xampp.
The root folder is "htdocs" where you would normally place Drupal, etc.
The site would be available at http://localhost/yourDrupalFolder WITHOUT htdocs .... If the Drupal files are not in their own folder but directly in htdocs (including the Drupal index.php file) then http://localhost/ ...

I thought this may help ...

jniesen’s picture

Hi,

I ended up installing Apache 1.3 and trying to get the site to run on that and its still spitting out garbage. The only two
possibities that I can think of are a database issue from when I imported into mysql or I have not set up mod_rewrite correctly.

Did I set up mod_write right?:

1.went into httpd.config and removed comment from
LoadModule rewrite_module modules/mod_rewrite.so
2. removed comment from AddModule mod_rewrite.c
3. Saved httpd.config and restarted Apache.

lionheart8’s picture

Hi
I am sorry I have not installed Apache on its own - and so would not know how to correct your problem, but as part of a package such as Xampp from http://www.apachefriends.org/en/xampp-windows.html, a package including Apache + MySQL - very easy to install - within about 10 min you can have your site running on your PC.
So I can only help regarding Xampp use.

If you decide to try it, I think you'd need to uninstall or disable any Apache & MYSQL servers you currently have active.

Install Xampp (for Windows) on your PC.
Towards the end of the installationm, it will ask if u want to install Apache & MYSQL as services. Say YES to both. This enables both to start automatically when u fire up your PC.

Place your drupal site in the file "htdocs".

You can access it http://localhost/yourDrupalfolder

Before that, go to http://localhost/phpmyadmin

To simplify things I create a database with a name exactly like the online DB ......

After that, go back to that phpmyadmin page.

Go to the link "Privileges"

Create a DB user with the same name as that online
Select Host "localhost" unless your online host is called something else

Give same password as online. [This helps you avoid editing files/default/settings.php] If any of the above is different, make sure you edit it otherwise there will be no DB connection.

Basically, you can access your site now at http://localhost/yourDrupalfolder

P.S. In case some links apart from the Frontpage dont work, you need to edit some File:

xampp\apache\conf\httpd.conf
and uncomment
#LoadModule rewrite_module modules/mod_rewrite.so

Restart xampp apache (If u installed it as a service, u need to do this via the Xampp Control Panel - If you did not install it as a service but start it manually via the C-Panel, use the same)

The links now work