Forum Replies Created

Viewing 1 replies (of 1 total)
  • Thread Starter mrdog

    (@mrdog)

    there were some extra char in my code that make the jam… now it works.

    plaese, include this code in the NEXT VERSION of the plugin. i’t svery useful:

    IN includes\CLASSES.PHP

    find this lines (about line 714) :

    // Special [wpcf7.remote_ip] tag
    
    			if ( 'wpcf7.remote_ip' == $matches[1] ) {
    				return preg_replace( '/[^0-9a-f.:, ]/', '', $_SERVER['REMOTE_ADDR']);
    			}

    insert below this:

    // Special [wpcf7.page_url] tag - by ADG
    			if ( 'wpcf7.page_url' == $matches[1] ) {
    				$pageURL = "http";
    				if ($_SERVER["HTTPS"] == “on”) {$pageURL .= "s";}
    				$pageURL .= "://";
    				if ($_SERVER["SERVER_PORT"] != "80") {
    					$pageURL .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"];
    				} else {
    					$pageURL .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];
    				}
    				return $pageURL;
    			}

    NOW YOU CAN USE in your mail message the tag [wpcf7.page_url] to insert the URL of the page WHERE the FORM was submitted.

    BYES!

Viewing 1 replies (of 1 total)