This topic is locked

Default code from main_view.php EVENT=(ViewOnLoad)

12/9/2008 1:22:08 PM
PHPRunner General questions
L
Lorenbond author

QUESTION: What is it for? How to implement the code?
This code is default code from main_view.php EVENT=(ViewOnLoad)
$_SESSION["message"]= 'http';

if ($_SERVER["HTTPS"] == "on") {$_SESSION["message"] .= "s";}

$_SESSION["message"] .= "://";

if ($_SERVER["SERVER_PORT"] != "80") {

$_SESSION["message"] .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"];

} else {

$_SESSION["message"] .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];

}

J
Jane 12/11/2008

Hi,
use custom event (Insert PHP code snippet option on the Visual Editor tab) for this purpose.