Forum Moderators: phranque
RewriteCond %{REQUEST_URI} !^/folderA [NC]
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
[edited by: incrediBILL at 5:59 am (utc) on Jul 3, 2014]
[edit reason] Exemplified [/edit]
either way I get the error message.
RewriteCond %{HTTP_HOST} ^example\.com RewriteCond %{HTTP_HOST} www\.example\.com The requested URL /folderA/subdomA.com/ was not found on this server.
RewriteRule zubzub http://www.example.com/whoopdedo.html [R=301,L] I have created, as suggested by lucy24, a .htaccess file and placed it inside the second domain. I firstly tried the code:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^2ndomain\.com
and then code:
RewriteEngine On
RewriteCond %{HTTP_HOST} www\.2ndomain\.com
but neither seem to be working.
so they can't do anything
If you want to access subdomainA at example.com/subdomainA then the folders and pages for folderA (primary domain) would need to be in the public_html folder.
If possible, look at your error logs for the affected time period and see what's up. Access logs and error logs overlap in the information they give. But problems with internal rewrites only show up in error logs.
Before you uploaded your script folders, what files were in your public_html folder? Was it only a folder called cgi-bin?
Can you view the folder's contents on your desktop to see if there is an index file in it
[Sun Jul 13 07:16:50 2014] [error] [client 86.144.218.143] File does not exist
The same error is repeated several times.
Yes there is an index.php file
public_html(primary domain) => folderA (folder)
The primary domain is in the folder public_html. public_html contains four folders, one for subdomainA, one for subdomainB, a folder called cgi-bin and folderA which contains the index.php file for the primary domain.
Would it be possible to create a .htaccess file to do something like this