cancel
Showing results for 
Search instead for 
Did you mean: 

Help needed please, .htaccess help

Jovetic
Grafter
Posts: 120
Registered: ‎17-12-2007

Help needed please, .htaccess help

I found this code that lets you point your domains to their own subdirectory within your CCGI space from another thread.
example.com/dir/file.php -> points to /files/home1/user/example/dir/file.php
ccgi.user.plus.com/another-file.php -> points to /files/home1/inspiration3/ccgi/another-file.php
The way i have my pages set up is:
www.jovtech.co.uk
on the FTP
httdocs/
Images [folder]
Pictures [folder]
Music [folder]
jovtech [folder]
Index.html
etc...
Then on my CGI i have;
http://ccgi.jovtech.co.uk/ccgi ; (at the moment i have reverted it back to http://ccgi.jovtech.co.uk/forums to make my links work again, will edit them again later)
ccgi/
and all of my forum conents within the ccgi folder
I created a file called ".htaccess"
There is a section i am to replace the text with whatever plus net assigned me homex its either 1,2 or 3.  I have not a clue.
RewriteEngine On
RewriteCond %{HTTP_HOST} ccgi\.jovetic\.plus\.com$
RewriteCond %{REQUEST_URI} ^(.+[^/])$
RewriteCond /files/homeX/jovetic/ccgi%1 -d
RewriteRule (.+[^/])$ /$1/ [r=301,l]
RewriteCond %{HTTP_HOST} ccgi\.jovetic\.plus\.com$
#RewriteCond %{REQUEST_URI} !^/ccgi
RewriteRule ^(.*)$ /ccgi/$1
RewriteCond %{HTTP_HOST} jovtech\.com$
RewriteCond %{REQUEST_URI} ^(.+[^/])$
RewriteCond /files/homeX/jovetic/jovtech%1 -d
RewriteRule (.+[^/])$ /$1/ [r=301,l]
RewriteCond %{HTTP_HOST} jovtech\.com$
#RewriteCond %{REQUEST_URI} !^/jovtech
RewriteRule ^(.*)$ /jovtech/$1
I am then to put the .htaccess file in the top directory folder, i am assuming the ccgi folder on my ccgi server?
If anyone could point out any errors i have made, or offer any advice it would be greatly appreciated, cuz before Tuesday i had never tried creating a propper web page and it has overtaken my life as i get easily taken over by challenges, this is my last hurdle, then i can watch a film and relax Smiley