Home arrow XAMPP Windows Manual
XAMPP Windows Manual
author: Chris Price
2007-12-15 -- this site
Previously on Pelaginox.com
© 2006 - 2009 A3webtech


XAMPP Windows Manual

Part 1 - XAMPP official docs
Part 2 -
XAMPP Windows Manual by A3webtech   -- this page

Page contents:
What is Xampp?
XAMPP download
Install XAMPP
Connect to XAMPP on the LAN
XAMPP with no router
Set up a simple LAN
Xampp folder location
Building a new site
Set up a single site
Multi-Site on XAMPP
CMS on XAMPP
XAMPP CMS method 1
XAMPP CMS method 2
Transferring the CMS to a server
XAMPP configuration menu
Initialising MySQL
How to find my.ini and my.cnf
Uninstall XAMPP
Reinstall using a 'Safe Mode' process
MySQL and WinSQLMyAdmin Password
Install as a Service
ASP on XAMPP
Windows 2003 Server issues
Windows Server 2003 vs XAMPP
Additional services - FTP, WebDAV
XAMPP questions
Xamp tips


This page, Part 2 of our XAMPP Guide, is entirely by A3webtech. It is not an official guide. It is an attempt to assist first-time users to get up and running quickly. It will help you especially if you have problems with MySQL initialisation, with the my.ini and my.cnf issues in WinSQLmyAdmin. It describes how to set up a site - how to connect to the server on the network - and how to install a CMS on XAMPP.


What is Xampp?
XAMPP for Windows turns any PC into a server. As stated in Part 1, it is suitable for a LANserver and development environment, not production (Internet use). A server = any PC with an HTML page serving application, that is, a program that receives requests from another connected computer and delivers web pages or files. Note that a server PC for local fileserving and website testing on a LAN can be any old, redundant PC, if its duties are not hard.

If the load is not heavy then an old clunker can be used as a server.
If the load is average, as on a well-used LAN in a very large office (perhaps 10 users or more online), then a reasonably modern PC should be used - but nothing special.
If a server is a production webserver, then a PC with a good spec should be used. The critical areas (in order of importance) are RAM memory (at least 2GB needed), a top-quality fast hard disk (such as a Seagate one), and a fast CPU (whatever is currently a fast model but at a reasonable price - no need to go overboard).

Read about XAMPP here:

http://www.apachefriends.org/en/xampp.html

For questions on compatibility, go here:
http://www.apachefriends.org/winxampp/win32-compatibility-current.txt


XAMPP download
Here we only discuss the Windows version. XAMPP installer versions are available for Windows, Linux, MacOS, Solaris and others. Make sure to download the correct version, which you can get here:
www.apachefriends.org/en/xampp-windows.html

You can ask questions in the forum at ApacheFriends, who are the XAMPP developers (it's basically a sub-project of Apache). They are based in Germany, so the main forum boards are in German. Scroll down the page to find the boards in English. The XAMPP Windows forum is here:
http://www.apachefriends.org/f/viewforum.php?f=16


Install XAMPP
Follow the installation routine on the previous page.

Then, set it up on the PC you installed it on. This is called a 'local machine' - it's one you can access directly - ie you can use the keyboard and see the screen. After this is done you can access the management via the network. (Of course, you can use remote access, but this is complicating matters.)


### First run: set up XAMPP on a local machine initially ###

A 'local machine' is a PC you have physical access to, and can access the keyboard & screen.

Some options can only be accessed this way; this is how Xamp is designed to be used in the current configuration. When using a local machine as a server, this is termed localhost working. The following instruction applies to operation on the local machine, not a LAN / remote PC.

Note: the convention is that letters and numbers between the < and the > are typed.


Boot up the server. Open the browser on the server (Internet Explorer for example) and type into the address bar <localhost/index.html>. You will see the example front page served by XAMPP. On some old browsers you may need to type the full version, <http://localhost/index.html>, but all modern browsers prefix it for you.

The program's useful features can be accessed from the Windows Start Menu, Xampp program group on the local machine. You should go to the Xampp Control Panel and use all the controls there, for maximum functionality. Test the server group functionality, and set the variables, by going to index.php. Follow all the left navbar menu items and resolve all options here. After Xampp is set up correctly, you can then access via the network, ie from another PC which is connected to the server PC.

An IP address on a local machine (the actual PC you are using) is commonly in the 127.0.0.1 range -- the last digit frequently 1 or somewhere between 1 and 10.


Connect to XAMPP on the LAN
On a LAN, the IP address will likely be in the 192.168.0.1 range -- the last digit varying from 1 thru 10. So, to connect to your server from another PC on the network, you type into the browser address bar the following:
192.168.0.1/index.html

With an old browser, Internet Explorer 4 for instance, you might have to type <http://> at the start.

If using a LAN PC as a server (a PC connected to your own via a cable or WiFi network), this is termed local IP working.

Some LANs use local IPs in the range 192.168.2.1 upward, or 192.168.0.100 upward. The router (switch, hub) determines this, so consult your router documentation for this (your wired or wireless router, that is to say your switch or WiFi router).


If you get into trouble here, then go to this site for a lot of useful info on local IPs:
www.portforward.com

Note that (on Windows) machine filepaths are backslashed:
C:\Program Files\apache

Network filepaths (both LAN and Internet) are forward-slashed:
http://127.0.0.1/index.php
http://www.a3webtech.com/index.php

XAMPP with no router

If you have no router (ie switch, hub, WiFi modem router), don't worry, you could use a USB PC-to-PC cable. A USB LAN like this usually has different IPs from the norm: the IP could be 169.254.222.68 for instance, depending on the manufacturer (this IP range is for the GeneLink USB LAN cable).

With no form of connection at all, XAMPP can still be used. Maybe you just have the one PC to work on. You can install the server application on your working PC. In this case the IP (the address of the server) is 127.0.0.1 -- so that's what you type into the address bar of your browser. It works, but is not ideal - a separate server is better.

Set up a simple LAN

For a simple, basic LAN - a local network - you only need some simple and inexpensive equipment. This is what you need:
  • any old PC - even an old 800MHz CPU PC will be suitable for light duties
  • a basic LAN hub, for cabled use (not WiFi) - this is only around £10 / $15
  • two LAN cables (to run from PC1 to the hub, and the hub to PC2)
  • LAN cards, or onboard LANs, on each of the PCs
This hardware is not expensive. No software is needed apart from XAMPP or another server application on the PC that is designated as the server. No software is needed on the client PC (ie your main working one) apart from a browser. A browser, such as Firefox or IE, is the software that connects to a server. Since this is a closed LAN there are less security implications than for Internet use.

You can connect as many PCs as you like (or other computers such as Macs). The capacity of the hub (aka switch) is the only limiting factor - the smallest is about 4 connections, and the largest in common use is 20. In practice there is no 'largest' as you can buy even larger ones, or chain them.

A simple alternative for temporary use is a USB PC-to-PC cable. You cannot use an ordinary A-to-A USB cable here, it won't work. It needs a micro LAN hub in the middle. This may be cheaper if the alternative is that you have to buy all of the other components. However there are usability issues as this is not a standard LAN - the IP addresses are unusual for example.

Xampp folder location

After installation, the Xampp root folder (the root directory) can be found at:
C:\Program Files\xampp\

The 'webroot' or web page folder (which is always one level below the root directory) is at:
C:\Program Files\xampp\htdocs

This folder is where you put files that can be accessed via the web (or in this case via the LAN).  In theory, any files in this folder can be seen from the web / LAN. A folder on a server is usually termed a directory - there is no difference between a folder and a directory.


Building a new site

First - clean up the web docs folder, /htdocs/.
Create a new folder in htdocs, called /old/.
Put all the current loose files in
htdocs into this (but not the folders such as forbidden etc).
Leave the folders there, as they are.

Your web pages should be placed in the \xampp\htdocs folder (not in \apache\htdocs\ as might normally be the case on a LAMP server, but this doesn't exist anyway).
Replace the included test-page index.html with your own front page.

The front page of your site is correctly termed the index page. It can also be called the home page, start page etc. Its filename is often index.html, as that is the convention. It can also be an .htm or .php file. There are alternatives but this is becoming too complex.

Note that you cannot run .asp pages on a LAMP server like this. Even though you are using a Windows PC, you have installed a separate server layer on top, and a standard server cannot run .asp or .net files.


Set up a single site
Usually, to serve a single site, your index and other 'front end' pages are placed loose in the htdocs folder. Then, other folders are added here such as images and separate sections for your website.


When using folders on a server, they are usually called directories. A directory = a folder, on a server. There is no difference. You can use either term, though for server use, it is more correct to use the term 'directory'. Here, we have used the term 'folder' more because it seemed better for these purposes, ie simpler. A folder = a directory.

When serving more than one website, each must be placed in its own folder. For multi-site use, then, you must put each 'site' in its own folder within /htdocs/. Therefore a local filepath to an index page for yoursite1.com, in a folder titled <yoursite1>, will be:

\htdocs\yoursite1\index.html

...and for each additional site:
\htdocs\yoursite2\index.html    ...and so on.

The URL for a single site, then, may be:

192.168.0.1/index.html  -- depending on the router. On the server itself (the local machine) it will be:

http://127.0.0.1/index.html

Multi-Site on XAMPP

...and for multiple sites would be:

http://192.168.0.1/yoursite1/index.html
http://192.168.0.1/yoursite2/index.html

...or on a local machine:

http://127.0.0.1/yoursite1/index.html
http://127.0.0.1/yoursite2/index.html
 

You will probably only need to type & Enter:

192.168.0.1/yoursite1


Internet hosts solve this multi-site name problem by setting up the DNS for each site on their servers direct into each site's folder, and thus lose the 'yoursite1' part of the URL.

When using multiple folders of web pages within a site (which is normal practice for  standard HTML sites), these are termed directories. You must ensure your navigation links are correct between directory levels.

How many sites on XAMPP

What is the maximum number of sites you can run on XAMPP? An infinite number, but limited by the PC's resources. In other words it doesn't matter. The largest I heard of is 30,000 (yes, 30k). In practice a MySql database is limited to about 50,000 entries such as pages. If you want to install 943 HTML or CMS sites, that's OK, it will work fine - for development of course, or LAN use.

For production, websites are limited to a max of 50 CMS / ecommerce / forum sites per shared hosting, for top performance. For good-quality shared hosting, sites are limited to 200 max. For average performance, 300 or 400 sites per server is acceptable - but if these are mainly database-driven sites then the database server will be heavily overloaded at times and this results in very slow page loading or even offlines.

But of course we are not talking about production servers here, XAMPP cannot be hardened for production except by an expert. And an expert would not be using it for that purpose, they would have no reason to do so if they can run a Linux / Apache or Linux / Nginx server.

CMS on XAMPP

Xamp CMS set-up is easy. This is the best way to test and build your CMS before transferring it to the web host. XAMP contains the MySQL databases and PHP scripting you need for CMS functionality. In theory the number of DBs (databases) you can have is unlimited. They are set up, like on a webhost, with phpMyAdmin.

Dynamic site engines, such as CMS applications, should be placed in the htdocs folder, and the installation run from here (unless the application states otherwise). Such site engine installation MUST NOT BE STARTED until its database is set up and running correctly (unless the application itself installs the database during first install). It is likely to fail otherwise, since dynamic functionality depends on the database.


Note that the 'pages' of a full-dynamic site - such as a CMS-driven site - do not exist: they are constructed on the fly by the dynamic application in conjunction with the database and server, and are therefore virtual pages. So, don't go looking for your web pages in htdocs - only the application folders (the CMS program itself) exist there. On a CMS or ecommerce application, THE PAGES DO NOT EXIST. They are built from the database, on-the-fly.

There is more server overhead with this method, although this is irrelevant in a development environment. Xampp provides a fully-developed *AMP environment for local testing of CMS and ecommerce sites.

XAMPP CMS method 1

Install the CMS files and folders LOOSE into the webroot. Do not put them in a folder (aka directory). Then, the test website URL will be:
192.168.0.1

This method ONLY works when there is just one site on the server. It is not advised. It is exactly what you do on a website, but on a test server you need to be able to run multiple sites.

Before running the CMS installer (or compiling it or whatever else is needed), first set up a database for it using phpMyAdmin.

XAMPP CMS method 2

This is the recommended method for a test server. It is not normally used on a website since there is no point - and it also creates an extra directory level in the URL that is not wanted.  This can be removed  by htaccess script, but why bother as it is unnecessary. On a complex website with more than one dynamic application co-installed on the same webspace, though, there may be a good reason to use this in-directory method. Only one app can exist loose in the webroot at any time (there are conflicts between all the files, especially index.php and htaccess).

Create a directory in the webroot called /yoursite1/ or whatever else you like. Create another called /yoursite2/. Install the test CMS or ecommerce set-ups into these folders. Of course, you can just place the entire CMS folder in there from somewhere else, and rename it to suit. Or, use FTP.

Then, your CMS URLs are:
192.168.0.1/yoursite1
192.168.0.1/yoursite2

You may need to enter:
192.168.0.1/yoursite1/index.php

You can have an unlimited number, in theory. You'll find el cheapo hosts in the States with around 3,500 sites on the same server, as an example. Most hosts limit the number of sites per server to 200 or 300. Quality hosts limit the number of sites on any one shared server to 50, otherwise site loading times slow down, partly due to overloaded database server issues.


Transferring the CMS to a server
After testing and trialling, you can then transfer your CMS or ecommerce app to the webhost. You can do this manually - get a fileset and a DB snapshot; or you can use a dynamic site cloner such as XCLONER from Joomlaplug. This works on any PHP-MySQL webapp.

This is a slightly complex area that rates another article, it isn't really part of the XAMPP material. Ask in our forum and we'll write it up...

XAMPP configuration menu

After your flat site (standard html pages) or dynamic site (CMS, PHP-driven etc) is up and running correctly, you can access the Xamp configuration menu via:

 ../old/index.php

...if you placed the original files in a folder called <old> as advised. The original index.php page is also reproduced at:

/xampp/index.php

...and can be browser-accessed here, should the original be overwritten during a dynamic site install.

Please view the full documentation for the individual applications, at their respective websites. They are linked from /index.php. Xampp cannot contain the full latest documentation for these apps, so it is always preferable to obtain them from source. In practice, database setup may be found to be the most troublesome for new users; please therefore view the full documentation at the mySQL site.

The additional applications within Xampp – those not part of the core *AMP environment – increase the functionality, and improve the ease of use. It must be stated from the start that open-source applications, of all types, will never be as user-friendly as normal Windows programs. The reasons for this are multiple and complex. Therefore, users are expected to consult the FULL DOCUMENTATION at the respective application websites. Several of these programs may need user-customisation of the variables in order to work in other than default configuration – especially as regards security.

XAMPP cannot be used as a production server for livesites as it is wide open. There is even a question-mark here on the matter of using a dev server like this, on a LAN which has an Internet connection. Some harden XAMPP and use it for production - but those issues are not for here.


Initialising MySQL

PhpMyAdmin is designed to be a user interface for mySQL. However, some initial mySQL variables may need to be set in advance, before phpMyAdmin can work. The .ini file is a possibility here.

The MySQL initial setup interface for Windows is called WinSQLMyAdmin, and may assist you here. It is accessed from the MySQL Admin button on the XAMPP control panel. If it flashes up and then closes, you need to click on the traffic-light icon in the system tray, which it has placed there, to open it again. In order for the system to work, all the .ini parameters must be correct and the SQL server connected and functioning.

BUT: WinSQLMyAdmin
needs to start up without MySQL running, or having been installed as a service, in order to create a new clean my.ini file.

Once again - if there are problems with database functionality:
WinSQLMyAdmin will need to create a new clean my.ini file. It cannot do that if MySQL is running; if MySQL is installed as a service; or if a my.ini file already exists, -- as it won't overwrite it.

If the XAMPP server does not function fully and correctly with a dynamic site, then the most likely cause is that the SQL service is faulty. This may be because the .ini file is incorrectly set up. The help files in WinSQLMyAdmin will assist you to correct this. Click the blue query (?) icon on the WinMySQLadmin control panel. If it cannot locate the Help file, drill down to:

\xampp\mysql\bin\

......and you will find it there (WinSQLMyAdmin.hlp).

The instructions in this help file are critical to getting the SQL service functioning correctly. In essence, you must enable the WinSQLMyAdmin Quick Setup panel (which is NOT the same as the main WinSQLMyAdmin panel). This creates its own .ini file and will get the service running correctly. You need to stop the SQL service (if installed), locate the my.ini and my.cnf files, rename them to .old, then restart the WinSQLMyAdmin procedure.

How to find my.ini and my.cnf

To do this:

1. Go to Folder Options. (In any folder, go to the top horizontal main text menu, choose Tools, choose Folder Options.)

2. Enable 'View Hidden Files and Folders', and 'View Protected System Files'.

3. Go to C Drive, locate and rename the my.ini file, which will now be visible. Name it my.ini.bak

4. Go to /xampp/msql/bin - locate and rename my.cnf, to my.cnf.bak

5. If there is no file my.cnf, but there is one called my -then that is the one you want. Rename it to my.cnf.bak

You can also find these files by Search. The my.cnf (MySQL config) file can be misidentified by Windows and may be named simply 'my', and/or be described as a Speed-Dial file, with the wrong icon (a modem or phone icon).

A file named my - with or without a speed dial icon - is the MySQL configuration file. Rename it.


Reinstall using a 'Safe Mode' process

If it didn't work first time, re-install using another method.

If the XAMPP server still does not function correctly, or if the MySQL or phpMyAdmin panels do not work fully, then the best option is to uninstall XAMPP using the following total uninstall method.

Uninstall XAMPP

Go to Control Panel >> Add/Remove Programs, and uninstall as per any Windows program.

Then go to
Program Files and delete the xampp folder.

Find and delete the my.ini and my or my.cnf files. This is CRITICAL – see above for the method.

Reboot the PC. It is now clean, and clear of XAMPP and MySql components.


Then, reinstall XAMPP like this:

  • Do not 'Install As A Service' XAMPP or any of its components, when asked by the installer.
  • Don't start Apache or MySQL; if they are running, stop them.
  • Do not set any usernames.
  • Do not set any passwords except for admin – set this to 'abc123' or whatever you want.
  • Leave the MySQL username as 'root', enter p/w 'abc123'.
  • First go to MySQL Admin on the XAMPP control panel, and start WinSQLMyAdmin (it kicks in automatically on first SQL boot, provided there are no my.ini OR my or my.cnf files.
  • On the first WinSQLMyAdmin screen, set u/n to 'root' and the p/w  to 'abc123'.

MySQL and WinSQLMyAdmin Password

You then have a username of 'root' for MySQL and WinSQLMyAdmin; a u/n of 'admin' for XAMPP; a password of 'abc123' for all. This ensures a trouble-free setup; when all is working OK you can then easily change u/n and p/w if necessary.

Install as a Service

Should you 'Install as a Service' or not? If your PC is mainly used as a server, then yes. If the PC mainly has other uses, and is occasionally used as a test server, then probably - no.

'As a Service' means that Xampp starts with Windows and runs as a main function of the machine. If you use the PC for other tasks then this probably isn't wanted as it loads the machine with several processes. But if you want to make sure that the server boot-up is trouble free, then you would do this.

It can be set in the install, or adjusted later via Windows >> Control Panel >> Administrative Tools.

ASP on XAMPP

You cannot use ASP pages or an ASP-based CMS on XAMPP because these need a Windows server. Even though the basic PC has a Windows OS, you have installed another layer on top, a server application, that does not use the Windows system or reference it in any way. There may be a commercially-available hack for this, but not free / open-source. If you want to run Windows server technology then you need to run a Windows server, not Apache server, which is standard web PHP - MySQL technology.

All you need to do, to have a Windows server (with any version of Windows), is fix up IIS so that it runs as a server manager. You can do this on any Windows box. You then have a Windows server and you don't need XAMPP. I wouldn't use it for production but it's up to you.

Windows 2003 / 2008 Server issues

If you have the specific Windows server package - Windows Server 2003 or 2008 - you don't need XAMPP. You can run ASP - .NET websites on this as this is what it is designed for. In addition this is production server technology, so as long as it is updated and maintained rigorously, this suits very well for production, ie web-facing use. ASP content management systems are designed for this - but you would probably also need MS SQL Server as well, the MS database application.

You can also use Windows Server 2003 to serve standard web technology based sites that use PHP or PHP - MySQL , such as normal PHP-type CMS. To do this you must install PHP and MySQL on the Windows server. This is a routine job though perhaps not for beginners. All Windows servers can have PHP and MySQL installed. In order to run a web-facing server you must upgrade, patch and maintain your server to professional levels or risk exploits. Common exploits include hacking a website and rigging it to download malware to any / all browsers that connect; and also compromising other sites on the server by XSS, cross-site scripting. In this way a badly-maintained server, and/or one with vulnerable web applications on it, can be turned into a malware farm. Web server security is not to be taken lightly, and these issues apply to all types of server.


Windows Server vs XAMPP pros and cons
XAMPP is best for:
- standard web sites that use flat HTML or PHP - MySQL dynamic technology
- LAN use
...but can't handle ASP sites

Windows Server 2003 is best for:
- ASP-based websites and ASP CMS or ecommerce.
- web-facing duties
...and it can handle PHP - MySQL apps, with additional software installed, but is perhaps not an optimal solution

A normal LAMP server is best for:
- webserver duties
- flat HTML sites
- PHP - MySQL dynamic apps
...but it cannot handle ASP sites

A web server is normally a Linux PC run for example on Red Hat or Centos, plus Apache, plus ancillary software including PHP, MySQL and Perl. However this cannot handle ASP websites of any kind.


Additional services

FTP

FileZilla provides FTP support for the server. You can test out the upload / download of files in bulk, and carry out directory maintenance, with this facility. Go to the FileZilla folder to set this up. You may find that the FileZilla service needs to be started at the XAMPP Control Panel, even if Installed As A Service. On a LAN it may be simpler to create a shared folder on each PC and transfer files between them.


WebDAV

To use WebDAV applications you must load the mod_dav modules, as described in Apache Notes (see previous page).


XAMPP questions

Q: How to set up two instances of XAMPP on one server ?
A: It looks as though you want to have xamp run many different sites. But it is not necessary to run several instances for this purpose, you can have 1,000 sites on one instance of XAMPP. See the multi-site explanations above. In fact we have seen 3,400 sites on one IP on a cheap US host :) -- and one IP normally lines up with one server.

There might even have been more sites on there with their own IPs. Probably not a great idea for production.



Q: Is XAMPP user-friendly ?
A: Definitely.

Although it is not aimed at novices, it is easy to use for basic tasks. It's a one-click install for most people; then just dump your web pages in the right folder, access the server via its LAN IP and you're away. You can install a hundred HTML sites if you want, or use CMS applications instead.


Q: Can I use XAMPP to serve a website on the Internet ?
A: You can use any server application for this.

However, security needs to be a consideration - maybe the main one. On XAMPP security is not a consideration at all, it's built for closed LANs, so that you can install a LAMP server on a Windows PC for local website development. Everything is designed to be wide open. It's an extremely clever and very useful device. For production (ie livesites), you are better off using a server that has had security built in as the first priority, not the last. There are plenty of people using xamp for production but they are taking a chance, as it can probably never be hardened to the level of a proper webserver.

XAMPP is not a proper webserver, it's a development tool. An expert might be able to harden it for production - but why would they do that when there are better tools available? If they are experts, they can use a real webserver instead. An expert can build and run a Centos - Lighttpd or Centos - NginX server for production, and that will do the job very nicely for high-load sites, it's all free, and essentially it can't be beat. A payware version is Red Hat - Zeus, equally good, posssibly better, who knows.

We know of no complete guide to hardening XAMPP for production. Given this, and the fact that you are asking basic questions about it, it would seem suicidal to use it in this way. OK for server techs and advanced computing techies perhaps, who would at least know what they are letting themselves in for. XAMPP has dozens of security holes that need patching to start with - and then you must monitor the security bulletins from the central orgs and upgrade PHP, MySQL, Perl, phpMyAdmin etc on a weekly basis. If you're up to that, give it a go.

Downside: fall down in one area, and your server will be exploited and one site will become a malware site, without you knowing. The other sites on the server will be exploited by XSS. The server becomes a malware farm and the search engines will ban all sites affected. You have to wipe the server, wipe the sites and start again. After this, you will be attacked with increased ferocity as you have proved easy to exploit - the search will be on for more loopholes, you're an easy target. And the search engines will watch you like a hawk.

Worth it? Up to you. This is what you pay a host $10 a year and up for. Seems like money well spent to me. What would you be doing that you can't pay $10 a year to someone to sort this out for you properly? Plus, you can get bulk domain deals if you are running loads of sites.

XAMPP is for dev not production - unless maybe you are an Apache - PHP - MySQL geek who prefers Windows to Linux :)


Windows Server 2003 + XAMPP
Q:  Might it be possible to run W2K3 (Windows Server 2003) plus XAMPP, in order to create an easy-install dual-purpose server for both PHP and ASP sites?

A:  This might be possible but there are multiple issues - and certainly not for novice server techs.

The idea of using this as a production server doesn't bear thinking about. For a start there is no complete tutorial available anywhere on how to harden XAMPP for production - and it may not be possible, in any case (to the level of a normal LAMP server). Plus, you then have the same basic issue with the W2K3 server. Plus there may be additional issues - so the workload to keep it patched for production would be high if not impossible.


Xamp tips

Tip #1

Comment-out
User variables: scripts sometimes need path variables and so on changed, for customisation. It will be useful for you to know that lines in scripts can be commented-out (temporarily disabled) by placing at the start of a line:

;      (semicolon - works on Windows .ini and registry files)
//     (2 x slash - works in PHP files)
#     (gate / hash / number symbol - works in htaccess files)

...or a tag enclosure of:

<!-- your text -->    (for HTML comments)
/* your text */        (for your comments in a CSS file)

These vary by code type. You should do this instead of deleting lines. You may have to remove the comment in some cases, to achieve full functionality.

Tip #2

How to open .ini, .php, .cgi, .pl files
Open them either with Windows Notepad, or preferably a full-feature editor such as NoteTab Pro. This gives you the line numbers, which is essential for locating script problems, as the error message is often 'error at Line 599, incorrect language parameter.....' etc.

Tags and so on are also highlighted with a full-feature editor, which helps a lot. The Mozilla Firefox browser is also useful here. Disable word wrap when viewing code.

Did you find this page useful?
If so, please consider linking to it. Thank you.


Please note that we do know how to spell XAMPP. It's sometimes spelt xamp, XAMP etc here so that people can still find the page easily in case of typos.

If you appreciate the help we have provided for you - which should solve some serious headaches if you are unlucky enough to be one of the people who experience problems with the XAMPP install - you can do one thing for us, to repay some of the effort we put into this. Link to this page from your website, or from a social bookmark service. We don't promote this website in any way except to ask people to link if they find it helpful. And drop in to the forum and say Hi. Thanks!

 
Ethical SEO Agency