ravish4ualways wrote:Am using XAMPP to host my website
Always best to include the version you have installed
ravish4ualways wrote:Now i want to redirect a link in the webpage on c:/xampp/htdocs to a folder in another drive (say D:/media) ....how do i go about it??
You can use an Alias to do this but use a vhost if you have multiple web sites to host on the one server.
You can add your Alias in the C:\xampp\apache\conf\extra\httpd-xampp.conf file - for example add your Alias after the webalizer Alias and before the last </IfModule> like so
Alias /webalizer "C:/xampp/webalizer/"
<Directory "C:/xampp/webalizer">
<IfModule php5_module>
<Files "webalizer.php">
php_admin_flag safe_mode off
</Files>
</IfModule>
AllowOverride AuthConfig
</Directory>
Alias /media "D:/media/"
<Directory "D:/media">
Options Indexes +FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</IfModule>
Change the folder to suit your situation as I have only used the detail you provided in your post.
Save the file and restart Apache.
Check the C:\xampp\apache\logs\error.log file for clues if Apache can't start after your edits.
Make sure that the text editor you use (notepad for example) does not save the file with a .txt extension automagically or you will get an error when starting Apache.
Read the C:\xampp\readme_en.txt file for help with security issues.
Make sure that WebDAV folder is deactivated - Advanced forum search in English Xampp for Windows will provide much detail about how to do this if you have not done so already and your version is pre 1.7.4 release.
Best wishes.