API15

JBrowser/isSSLConnection: Difference between revisions

From Joomla! Documentation

Doxiki (talk | contribs)
New page: ===Description=== Determine if we are using a secure (SSL) connection. <span class="editsection" style="font-size:76%;"> <nowiki>[</nowiki>[[Description:JBrowser/isSSLConnection|Edit ...
 
m preparing for archive only
 
(2 intermediate revisions by the same user not shown)
Line 2: Line 2:
Determine if we are using a secure (SSL) connection.
Determine if we are using a secure (SSL) connection.


<span class="editsection" style="font-size:76%;">
<nowiki>[</nowiki>[[Description:JBrowser/isSSLConnection|Edit Descripton]]<nowiki>]</nowiki>
</span>


{{Description:JBrowser/isSSLConnection}}
 
<! removed transcluded page call, red link never existed >


===Syntax===
===Syntax===
Line 30: Line 28:
</source>
</source>


<span class="editsection" style="font-size:76%;">
 
<nowiki>[</nowiki>[[SeeAlso:JBrowser/isSSLConnection|Edit See Also]]<nowiki>]</nowiki>
<! removed transcluded page call, red link never existed >
</span>
{{SeeAlso:JBrowser/isSSLConnection}}


===Examples===
===Examples===
<CodeExamplesForm />
=== Code Examples ===
<dpl>
<dpl>
  noresultsheader=\n
  noresultsheader=\n
  category=isSSLConnection
  category=isSSLConnection
  category=JBrowser
  category=JBrowser
  category=CodeExample
  namespace=CodeExample
  category=MethodExample
  category=MethodExample
  include=*
  include=*
  format= ,,,
  format= ,,,
</dpl>
</dpl>
[[Category:Archived pages API15]]

Latest revision as of 00:19, 25 March 2017

Description

Determine if we are using a secure (SSL) connection.


<! removed transcluded page call, red link never existed >

Syntax

isSSLConnection()


Returns

boolean True if using SSL, false if not.

Defined in

libraries/joomla/environment/browser.php

Importing

jimport( 'joomla.environment.browser' );

Source Body

function isSSLConnection()
{
    return ((isset($_SERVER['HTTPS']) &&
        ($_SERVER['HTTPS'] == 'on')) ||
        getenv('SSL_PROTOCOL_VERSION'));
}


<! removed transcluded page call, red link never existed >

Examples

Code Examples