This topic is locked

Track logins and changes

6/25/2006 14:14:55
PHPRunner General questions
O
osluk author

function AfterEdit()

{

//** Insert a record into another table ****

global $conn;

$IP = $_SERVER["REMOTE_ADDR"];

$User = @$_SESSION["UserID"];

$AccessType = "Login";

$strSQLInsert = "insert into audit (IP,User,DateTime) values ('$IP','$User',NOW())";

db_exec($strSQLInsert,$conn);
}
$AccessType = "Login";

$AccessType = "Some_thing";

$AccessType = "Some thing";
I can only get Login to be written to the table.
What is the correct syntax?
Cheers Chris

Alexey admin 6/26/2006

Chris,
$AccessType variable is not used in your code, so it can not get to the table.

O
osluk author 6/26/2006

Thanks