Page 1 of 1

Using XAMPP on a Removable Disk

PostPosted: 21. November 2009 03:35
by LeeHarvey009
i have installed XAMPP installed on my Seagate FreeAgent Drive (F:) Removable Disk
for the sake of portablity

i have a load of files and folders on this removable Disk i want to process using PHP...

but i would have to move every file and folder to htdocs folder

why am i confined to running PHP pages in the F:\XAMPP\xampp\htdocs folder

is this the only way...is there a way where i can keep every thing in place with out moving things into the htdocs folder.

any help would be great...cheers

Re: Using XAMPP on a Removable Disk

PostPosted: 21. November 2009 06:05
by Izzy
You can use an Alias directive in the \XAMPP\xampp\apache\conf\extra\httpd-xampp.conf file.

Make sure that if you add an Alias that it goes between
<IfModule alias_module></IfModule>
Usually just after the webalizer entry would be an appropriate place.

After editing make sure you save and restart Apache but first make a backup copy of the file.

http://httpd.apache.org/docs/2.2/mod/mod_alias.html#alias


Here is an example:
Code: Select all
Alias /phppages /myphppages
<Directory /myphppages/>
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
Of course in the above example replace the relative path details I included with your own.