Unable to access index page of my site


#1

I’m not sure what I’ve done but in making some changes to my website, the main url no longer works properly. With IE Explorer, if I enter mysite.com, www.mysite.com, http://mysite.com or http://www.mysite.com, I get a prompt asking me “Do you want to save this file, or find a program online to open it?”

If I go to http://mysite.com/index.html with Internet Explorer, the page loads but if I enter http://mysite.com/index.html with Firefox I get a similar prompt.

I can directly open other pages/directories on my site with no problem.

I tried restoring my site but the problem still exists.

Looks like I won’t hear from customer support till sometime after 9am PST.

Has anybody else ever run across this problem? Any advice would be appreciated.


#2

There could be a .htaccess file throwing things off, but without the URL of your site, there’s no way for us forum users to test what’s going on with your site. Have you tried saving the file to see what it is?


#3

Thanks, it was a problem with my .htaccess file. The following line was the problem:

Customer support commented it out and replaced it with this:

That got my page to load properly but caused server side includes to stop working on my .htm and .html pages so I commented out that replacement line as well.

Here’s what’s in my current .htaccess file:

[quote]AddHandler server-parsed .html .htm
addtype text/vnd.wap.wml wml
#AddType application/x-httpd-php .php .html
#AddHandler application/x-httpd-php5 .php .htm .html[/quote]

I suspect that the change to my .htaccess file occurred when I was installing an xml include in one of my directories which only seems to work with .php pages. Interestingly enough, the xml include seems to be working just fine without it.

Out of curiosity, could you tell me what exactly those commented out lines are supposed to do? Any idea why the first one “broke” my site and the second one caused server side includes to stop working for me?

In any case, thanks and I hope this information proves helpful to someone in a similar situation in the future.


#4

The first version caused all the HTML pages in your site to be served with the MIME type application/x-httpd-php, which caused the browser to think the data was some type other than HTML and prompt you to save it as a file. M$IE often second-guesses MIME types to do what it thinks the developer really wants, while Firefox follows the standards more closely, which is why the page sometimes worked in M$IE in this setting. The second version of your file, with that commented out, served the files in the default server setting of text/html, which is the proper type, but didn’t cause server side processing for PHP commands to take place. The final setting you used caused the PHP to be parsed and executed at the server end before sending output as type text/html, so things worked correctly all around.