Hi guys.
Sorry for what might seem like a simple question...but:
I have installed XAMPP, and XAMPP control panel.
They appear to work fine, I unzipped it to the root of my flash drive like i read to do, opened up the control panel, started Apache, Mysql - went into phpmyadmin, made a DB and some tables inside it.
I also have notepad++ installed from before, I created a simple page with just initializing a variable and then echo'ing it - however when previewed in Firefox it does not show the PHP elements.
Am I missing some obvious step here?
Many thanks,
Rich
I don't know. Unless I don't understand correctly, this is basically how I run my setup. Is there a problem with your MySQL username and password?
Have you tried simple PHP statements (without MySQL) to see if they work?
ex.: $test = 2 + 3; echo $test
And, the very basic, are you using the ".php" extension? If not, the Apache processor won't treat it and Firefox will consider it as a pure html page.
Basically, I develop a few websites using XAMPP, PHP and MySQL. My setup is the following:
– Current XAMPP setup as defined here:
https://portableapps.com/apps/development/xampp
– I develop a few websites with different web addresses, so I changed the configuration file in (use Notepad and follow instructions included in the comments of that file):
X:\xampp\apache\conf\extra\httpd-vhosts.conf
For example, I have:
NameVirtualHost *:80
ServerName localhost
DocumentRoot "X:/xampp/htdocs"
ServerName abc.localhost
DocumentRoot "X:/SITES/SiteABC"
...
where "SiteABC" folder is essentially my local/development copy of the site hosted at http:// abc dot com. It is stored on my portable drive.
All other sites are similarly defined, with a local address at http://xxx.localhost
To go *beyond* the localhost address, you need – in theory – to modify your "hosts" file. Instead of doing that, I prefer to use an extension on my copy of Firefox Portable. That way, it works everywhere...
So I use the FoxyProxy Standard extension (http://addons.mozilla.org )
with the following rules configured:
– default rule: at the bottom (i.e. last rule read)
– Local server rule: at the top (i.e. first rule read)
Info tab: *Manual Proxy: host at: 127.0.0.1
URL pattern (only one rule): http://*.localhost/*
Michel Gagnon
Montréal (Québec, Canada)