Reputation: 19
Is there a HTTP environment variable I can use to work this out?
Upvotes: 0
Views: 210
Reputation: 41080
Apache sets an HTTPS
environment variable to the value 1 or "on" when the request was made trough SSL. Note that this flag is not present on simple HTTP requests.
Upvotes: 1
Reputation: 2077
What are you using at server side. If you are using java servlet then you can get URL information as follow:
String scheme = request.getScheme();
String serverName = request.getServerName();
int portNumber = request.getServerPort();
Upvotes: 1