.13 on IIS on XP error

Help with getting the CMS CORE package up and running. This does not include 3rd party modules, PHP scripts, anything downloaded via module manager or from any external source.
Locked
thestormdragon

.13 on IIS on XP error

Post by thestormdragon »

Hi

New install of 0.13 running on Win XP, SP2 (IIS 5.1) with mySQL 4.1.20

Installation worked happily but get this error at the top of the page:

Notice: Undefined index: QUERY_STRING in C:\Inetpub\wwwroot\index.php on line 41

Clicking on any link just produces a page cannot be found error and I think it's something to do with the URL processing as the link is

http://127.0.0.1/index.php/content_types

when I think it should be

http://127.0.0.1/index.php?page=content_types

Any ideas?

Thanks in advance

David
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am

Re: .13 on IIS on XP error

Post by Elijah Lofgren »

Hmm... IIS must not treat content_types as a query string in URLs like this (I'm guessing Apache does):
http://127.0.0.1/index.php/content_types

If you want to just use URLs like this:
http://127.0.0.1/index.php?page=content_types

Open config.php and change this line:

Code: Select all

$config['internal_pretty_urls'] = true;
to:

Code: Select all

$config['internal_pretty_urls'] = false;
And I just noticed that in the comments above that line it says "This will not work with IIS", so I guess this is a known problem.

internal_pretty_urls will be turned off by default in future versions of CMSMS.

Hope this helps,

Elijah
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
thestormdragon

Re: .13 on IIS on XP error

Post by thestormdragon »

Hi Elijah

Firstly, thanks for your help - making that change has fixed 99.99% of the fault!

All pages / links etc now work without any problem apart from:

http://127.0.0.1  when I still get exactly the same error (Notice: Undefined index: QUERY_STRING in C:\Inetpub\wwwroot\index.php on line 41)

However, if I click the home link (which has the URL http://127.0.0.1/index.php?page=home) then the error doesn't appear.

And yes, I did clear the cache!!

Thanks again

David
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am

Re: .13 on IIS on XP error

Post by Elijah Lofgren »

thestormdragon wrote: Hi Elijah

Firstly, thanks for your help - making that change has fixed 99.99% of the fault!

All pages / links etc now work without any problem apart from:

http://127.0.0.1  when I still get exactly the same error (Notice: Undefined index: QUERY_STRING in C:\Inetpub\wwwroot\index.php on line 41)

However, if I click the home link (which has the URL http://127.0.0.1/index.php?page=home) then the error doesn't appear.
It looks like this has been fixed in the SVN version (unreleased, CMSMS-1.0-svn).

In index.php, try finding this:

Code: Select all

if (!isset($_SERVER['REQUEST_URI']))
{
	$_SERVER['REQUEST_URI'] = $_SERVER['PHP_SELF'] . '?' . $_SERVER['QUERY_STRING'];
}
and replacing it with this:

Code: Select all

if (!isset($_SERVER['REQUEST_URI']) && isset($_SERVER['QUERY_STRING']))
{
	$_SERVER['REQUEST_URI'] = $_SERVER['PHP_SELF'] . '?' . $_SERVER['QUERY_STRING'];
}

That will probably fix your problem.  ;)


Edit: fixed code quotes.
Last edited by Anonymous on Wed Jun 28, 2006 4:06 pm, edited 1 time in total.
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
thestormdragon

Re: .13 on IIS on XP error

Post by thestormdragon »

Hi Elijah

What a star!  It all works perfectly now.

Many thanks once again

David
Locked

Return to “[locked] Installation, Setup and Upgrade”