I put is as such in my apache2.conf:
I then put the files index.php and secret.txt in the folder /media/space. If I access my site (site.com:8029) I see the contents of my php file.PHP Code:<VirtualHost *:8029>
ServerName "Mine"
DocumentRoot /media/space
</VirtualHost>
<Directory "/media/space">
RewriteEngine On
RewriteRule ^(.*)$ index.php?request=$1 [L]
</Directory>
If I access the secret file (site.com:8029/secret.txt)
.
.
.
.
I SEE THE CONTENT OF THE INDEX.PHP FILE!!! Thank you so much! I'll find a way to do all the nice neat programming around this now.
Oh, BTW. Just thought I'd mention for any newbies that read this thread some time, I had to include a module to use the code kows provided. The module is called Rewrite and in linux you can add it to apache by doing the following i a terminal:
Thanks again Kows!Code:sudo a2enmod rewrite sudo /etc/init.d/apache2 restart





Reply With Quote