Hello Everybody :-)

I've been trying to figure something out, but just cant find the right
answer.

I need some code to check that the page is being viewed from a specific url.
EXAMPLE: Not just http://www but https://www1 if it is https://www1 then
show the page otherwise echo a message.

The reason is I don't want people to view certain pages without the secure
server connection.

I thought along these lines:
$url=parse_url( some code to get the current URL); //Not sure how to do that
part.
if ($url[scheme] != 'https'){
    echo "This page must be viewed on a secure connection - Please use the
links";
 }else{
Rest of Page Information
}


What do you rekon,
Am i close or miles off.

Any help would be really great.

YoBro



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to