caldera_forms_get_current_url

Get current URL.

Description

(string) caldera_forms_get_current_url(); 

Returns (string)

Current URL


Usage

  1. if ( !function_exists( 'caldera_forms_get_current_url' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'caldera-forms/processors/functions.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = caldera_forms_get_current_url(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/processors/functions.php  
  1. function caldera_forms_get_current_url() { 
  2. $url = 'http'; 
  3.  
  4. if ( isset( $_SERVER[ 'HTTPS' ] ) && 'off' != $_SERVER[ 'HTTPS' ] && 0 != $_SERVER[ 'HTTPS' ] ) 
  5. $url = 'https'; 
  6.  
  7. $url .= '://' . $_SERVER[ 'HTTP_HOST' ] . $_SERVER[ 'REQUEST_URI' ]; 
  8.  
  9. return $url; 
  10.