Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2009-02-04 00:06:45

johnsanders
New Member
From: SF Bay Area, USA
Registered: 2009-02-02
Posts: 7
Website

Clean URLs on Textpattern 4.0.8, extra HTML (HTTP 200 messages)

I have a goofy one I can’t seem to figure out. I have installed my first 4.0.8 installation and I’m having issues with clean URL’s. When I turn them on, the diagnostic screen says everything’s ok, and they function as expected. I do most of my development in Firefox 3, but started noticing that the page was slow and it wouldn’t always render the page correctly. After confirming it wasn’t an issue with my setup, I started testing on other browsers. Here’s a snip from the bottom of one of my pages when I do view source in IE6.

...
      </div><!-- #footer -->
    </div><!-- .pageInnerWrapper -->
  </div><!-- .pageWrapper -->
</body>
</html>
<!-- Runtime:    0.0187 -->
<!-- Query time: 0.012596 -->
<!-- Queries: 13 -->
<!-- Memory: 2085Kb, end of textpattern() -->
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>200 OK</title>
</head><body>
<h1>OK</h1>
<p>The server encountered an internal error or misconfiguration and was unable to complete your request.</p>
<p>Please contact the server administrator, [no address given] and inform them of the time the error occurred, and anything you might have done that may have caused the error.</p>
<p>More information about this error may be available in the server error log.</p>
</body></html>

After the page is requested from the host, it’s returned with an extra HTML document in the bottom. It’s somehow receiving what looks like an HTTP 200 response attached to my HTML document. Different browsers handle this situation differently. It was hard to notice with Firefox because I believe Firefox is stripping off the extra HTML and displaying the page correctly (for the most part). However, IE doesn’t do this. IE just tries to display the response back as it was sent with the extra HTML attached. I can’t believe I’m saying this, but if it wasn’t for IE6, I’m not sure how easily I would have figured out what I know so far. Thank you Microsoft.

If I turn on messy URL’s in the preferences area, then the pages seem to work normally. A view source in IE6 shows that it receives the correct HTML document with no added stuffs. All my browsers start working as expected at this point and no goofiness occurs.

I’m really stumped as to where to start looking for the problem. Any advice on how to proceed from here would be greatly appreciated.

- John

Last edited by johnsanders (2009-02-04 00:43:21)

Offline

#2 2009-02-04 00:57:40

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: Clean URLs on Textpattern 4.0.8, extra HTML (HTTP 200 messages)

Same problem here. (Not that that helps, sorry.)

Offline

#3 2009-02-04 04:51:25

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,357
Website GitHub Mastodon

Re: Clean URLs on Textpattern 4.0.8, extra HTML (HTTP 200 messages)

Offline

#4 2009-02-04 06:33:30

johnsanders
New Member
From: SF Bay Area, USA
Registered: 2009-02-02
Posts: 7
Website

Re: Clean URLs on Textpattern 4.0.8, extra HTML (HTTP 200 messages)

I figured it out. It was an issue with my .htaccess file. I had to uncomment the RewriteBase setting and change it from the default to RewriteBase / . That seemed to do it. I verified the problem was gone by sniffing my HTTP traffic.

I’m guessing that the issue with needing to change the rewrite base was because this particular instance of textpattern did not reside in the /htdocs root folder, it’s in a subfolder (/htdocs/textpattern).

- John

Offline

Board footer

Powered by FluxBB