_SERVER["DOCUMENT_ROOT"] problem with windows servers

I am running my website on windows server and I am faicing
SERVER[“DOCUMENT_ROOT”] problem with my website…

I’ve tried it converting it using…


if(!isset($_SERVER['DOCUMENT_ROOT']))
	{ if(isset($_SERVER['SCRIPT_FILENAME']))
		{$_SERVER['DOCUMENT_ROOT'] = str_replace( '\\\\', '/', substr($_SERVER['SCRIPT_FILENAME'], 0, 0-strlen($_SERVER['PHP_SELF'])));
		};
	};
	if(!isset($_SERVER['DOCUMENT_ROOT']))
	{ if(isset($_SERVER['PATH_TRANSLATED']))
		{$_SERVER['DOCUMENT_ROOT'] = str_replace( '\\\\', '/', substr(str_replace('\\\\\\\\', '\\\\', $_SERVER['PATH_TRANSLATED']), 0, 0-strlen($_SERVER['PHP_SELF']))
			);
	};
};

in my php info file its showing:
_SERVER[“DOCUMENT_ROOT”] C:\HostingSpaces\rksmatri\aimanews.com\wwwroot

when I run the script in browser it flagging with the error:

Firefox doesn’t know how to open this address, because the protocol (c) isn’t associated with any program

Please let me know how can I fix this…

Thanks

Most forums don’t like it much when your crosspost.

Yes Doug G,

Sorry for that as I normally post it once…but after posting in php section I realized that I post it on wrong category…that’s why I posted it here… so that I would be able to have a better solution…

And I am not permitted to move my thread…:frowning:

Sorry for the inconvenience…bt I can’t delete my post tooo…:frowning:

I was only mentioning … :slight_smile: