|
#1
|
|||
|
|||
|
I have created my MAIN site, using the Soholaunch builder. It was a move over from another hosting provider. Since my old site was made using basic .html extensions, I have used 301 redirects in my .htaccess file to make sure any old links are being redirected to the new site. That was all working fine, UNTIL I added a addon domain which I built using Joomla.
What was happening is that any time you typed in the addons domain, it redirected to my main domain, they are completely different companies and/or sites. I finally figured out it was this line in my .htaccess document that was doing it: redirect 301 /index.html http://www.maindomain.com/Home_Page.php So for the time being, I removed that line, and created a custom 404 error page to hopefully redirect customers to use the navigation to access the new (main) site. Anyway, what I need to know is HOW I can redirect my old index.html files (for my MAIN domain) to the new .php version WITHOUT also causing my addon domains to be redirected to it as well. Is there a way to do this? |
|
#2
|
||||
|
||||
|
If they are in the same directory, you could try simply removing the index.html file--the server should then offer index.php.
|
|
#3
|
|||
|
|||
|
Well, the addon domain is in it's own folder, but that folder is within my public_html folder of the main site. That's how cpanel created it when I added it in.
I actually DON'T have an index.html file anymore in the main directory. But I have a lot of OLD back-links that point directly to that page so I get a number of people coming to my site that way. My original solution of adding the redirect in my htacces worked UNTIL I added the addon domain, now that domain is being re-routed over to my original site. Removing the redirect to the custom error page I made, just sends those people to a "hostgator" error page. Is there something I can add in my htaccess file in the SUBDOMAIN that will work? Or does the server read the main site's htaccess first, EVEN WHEN the domain being called up is the sub-domain? Or is there some way to redirect all old html links to my new homepage? For example: www.mydomain.com/anyoldpagehere.html would redirect to www.mydomain.com/homepage.php Thank you for the suggestion and trying to help. I really appreciate it. |
|
#4
|
||||
|
||||
|
I was referring to the addon's directory...does it have both an index.html and an index.php? If so, remove the index.html file and the server will offer index.php.
.htaccess files work for every directory under the one in which they are placed, until there's another one, which in turn works for every directory under it. |
|
#5
|
|||
|
|||
|
No, There is no index.html in the main folder of the subdirectory. There is an index.html in lots of other folders, but they have nothing in them except background color information. These were installed by Joomla during installation. I tried removing the index.html file from the "template" directory but that didn't work either. Since I am using a custom joomla template, I assumed that was where it would look first, behind the main subdirectory folder.
|
|
#6
|
|||
|
|||
|
Hostgator Live Chat was able to help me fix it.
They put Code:
DirectoryIndex index.php Both sites seem to be working correctly now. Thank you very much for trying to help! |
![]() |
| Bookmarks |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Fascinating problem with .htaccess and addon domain | paradigm | Shared Hosting Support | 14 | 04-08-2010 10:02 AM |
| Addon Domain Problem | Tayrak | Shared Hosting Support | 10 | 05-21-2008 09:32 AM |
| htaccess - Redirecting from a directory to a different domain | Chimpie | Shared Hosting Support | 1 | 03-04-2008 05:35 PM |
| addon domain redirecting to sub domain!? | ryanhellyer | Shared Hosting Support | 5 | 03-21-2007 12:48 AM |
| Addon domain problem, should I wait 24-48 hours before adding new domain? | osakka | Shared Hosting Support | 1 | 10-01-2006 08:12 PM |
All times are GMT -5. The time now is 03:09 AM.









