Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2008-01-14 13:11:03

good.glock
New Member
From: UK
Registered: 2008-01-14
Posts: 2

Clean URL test failed (but clean URLs are working I think)

Hello.

Texpattern diagnostics, says that the clean URL test has failed, although I believe that clean URLs are working, because the site works with permanent link mode set to /section/title.

Perhaps just the test is failing for some other reason? In include/txp_diag.php line 318 kicks off the clean URL test:

$pretext_data = @file(hu.$s.’/?txpcleantest=1’);

I removed the @ (error suppression) and ran it again, which displayed:

“Warning: file(http://[mydomain]/fc86da5da134d738a3b88447a17d32c9/?txpcleantest=1) [function.file]: failed to open stream: Connection refused in [relative_file_location]/public_html/textpattern/include/txp_diag.php on line 318”

along with the diagnostic page itself. So the server is refusing the file read via http. The PHP variable $pretext_data is empty when the script comes to test its returned value.

Then, I typed the “http://[mydomain]/fc86da5da134d738a3b88447a17d32c9/?txpcleantest=1” into a browser URL bar and it displayed “0e41dfbead508a7eba009cd21bbb8603”, probably as expected.

I have consulted my hosting provider, they have confirmed that allow_url_fopen is ON, but that they disallow file reads via http, as a security measure, so I think the Textpattern diagnostic test for clean URLs is giving a false fail because of its technique of using a file read via http.

1) Does anyone have any experience of this, to confirm (or deny) what I have found?

2) Has anyone got any advice to offer, to help get a clean URL test that works when using a hosting provider who has disabled file reads via http?

Thanks to anyone who can help.

Last edited by good.glock (2008-01-14 13:15:11)

Offline

#2 2008-01-14 13:26:59

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: Clean URL test failed (but clean URLs are working I think)

If clean urls work, there’s no need to look at the clean urls test in diagnostics. Diagnostics is mostly useful in situations where something does not work ;)

Requesting a file by HTTP is the only way to test if clean URLs work. I’ve heard stories of ISPs that allow only 1 simultaneous connection (loading diagnostics + clean url test = 2 connections) or ISPs that do not allow the webserver itself to request a page on its own server.

Offline

#3 2008-01-14 14:04:42

good.glock
New Member
From: UK
Registered: 2008-01-14
Posts: 2

Re: Clean URL test failed (but clean URLs are working I think)

Thanks for the advice. Nothing to worry about. And if file read by http is the only way to test clean URLs, then it’s no good me complaining that the test isn’t very good!

Regards,
Good.Glock.

Offline

Board footer

Powered by FluxBB