<p>Does anyone of you know, if and if so, how can I check, with my application code, if a server has ssl enabled or not?</p>

not sure on your language of preference but here it is in c#
```
```
public bool IsSecureConnection()
{
    return HttpContext.Current.Request.IsSecureConnection || 
           HttpContext.Current.Request.Headers["HTTP_X_SSL_REQUEST"].Equals("1");
}
```
```
Please note this header is custom, but I think you get the idea.  I've seen folk simply query request for "https" and besides looking dirty it's probably reasonably acceptable, depends on your security model.
Or are you asking whether it's simply available at all?
I