I downloaded WAMP onto my computer so I could play around with a website on my computer, the websites at http://sunnybeachvacations.com/index.php?pag=0
so I FTP and downloaded the contents into the wamp/www/ibtravelin
Started WAMP and this is what I get. (screenshot)
Sorry, Luke, I don’t speak (or read) what appears to be Spanish in very small print.
I would expect WAMP to have created an installer which would avoid the protected directories on a Windows box (e.g., Users and Program Files) so the problem may be with the IP address which the normal install of Apache is looking for (127.0.0.1 and domain of localhost - you can add your local domain name via the httpd-vhosts.conf file and the C:\Windows\System32\drivers\etc\hosts file. It’s likely that your production server has mod_rewrite enabled but Apache does not do that by default so you’ll have to get into the httpd.conf if you’re relying on redirections via .htaccess.
Something which was a problem in the XP days was that IIS was given an autostart using port 80 so that had to be Stopped and told to Manual start in the future.
I’m sure that there’s a myriad of other things which could be wrong but that’s my limit - unless you want to try to match your production server’s configuration with individual daemon installations in which case most of the above applies, i.e., STOP/Manual start IIS, MySQL (remember your root password; let it install in Program Files, its location is unimportant except for backing-up your local database), install Apache (in its own directory - I use a separate partition to keep away from Windows’ protected directories), then install PHP (it’ll change the httpd.conf for you - play keep away with Windows on this, too) and complete the process installing and configuring PHPMyAdmin (here’s where you’ll need the MySQL password).
I don’t bother keeping my local domains (generally acronyms for the online domains) in the htdocs (or your www) directory as the httpd-vhosts.conf (and hosts) file allow me to specify the physical location of the domain on my test server.
Apparently Kevin Yank has abandoned the daemon packages for the “snapshot” view but I can send you a copy of an older PDF of the free version of his book - or my notes which, for me, better organized the process. Just PM and I’ll go look for it.
I hope something in this blather will help resolve your problem with WAMP.
Looks to me like it’s just outputting the contents of the script. Check php.ini for short_open_tag and set it to “on” and restart Apache/WAMP. Or replace <? at the start of the script with <?php
If you’re correct, then the PHP needs to modify the httpd.conf, too, adding the AddType application/x-httpd-php .php line to tell Apache not to display .php extension files, only their output. Hopefully, WAMP got that into Luke’s code.
I don’t think that’s the case. Although WAMP certainly isn’t perfect (by a longshot), it does set up Apache correctly to serve PHP files.
The thing that seems to be going on here is that php doesn’t know it should parse php files that just start with <? as opposed to <?php, which is governed by the php.ini setting short_open_tag.
From the manual:
Tells PHP whether the short form (<? ?>) of PHP’s open tag should be allowed. If you want to use PHP in combination with XML, you can disable this option in order to use <?xml ?> inline. Otherwise, you can print it with PHP, for example: <?php echo ‘<?xml version=“1.0”?>’; ?>. Also, if disabled, you must use the long form of the PHP open tag (<?php ?>).
Aha! I couldn’t see that in the tiny image and, being in Spanish, I didn’t bother looking at the … er, code? Your eyes are better than mine so that’s probably correct (although the more common problem used to be the AddType handler in httpd.conf). Good pick-up.