Hello, here's one for you all.
What is the fastest way to find out what protocal a script is being
called from ?
IE http, https, ftp ,etc
currently I have to use :
sub set_prot {
use CGI self_url;
$self_url_query = CGI::new();
$self_url = $self_url_query->self_url();
if($self_url =~ m/^https\:\/\//i) { $http_prot = 'https'; }
else { $http_prot = 'http'; }
return $http_prot;
}
I know there's got to be a better/faster/shorter way
Mainly interested in http and https so that generated html can be like
this :
<img src="$http_prot\://domain.com/images/pic.png">
That way if the page is access via http
<img src="http://domain.com/images/pic.png">
but if it's accessed via https it's
<img src="https://domain.com/images/pic.png">
And then you won't get the not so good "not all items on this page are
secure" bit.
Any ideas?
Thanks
Dan
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
- Help with end-time sta... Scott, Deborah
- Re: Help with end... R. Joseph Newton
- Re: Help with end... John W. Krahn
- RE: Help with end... Wagner, David --- Senior Programmer Analyst --- WGO
- RE: Help with end... Scott, Deborah
- Re: finding p... Dan
- Re: findi... simran
- Re: f... Dan
- RE: Help with end... Bob Showalter
- RE: Help with end... Scott, Deborah