Ignore:
Timestamp:
Jan 30, 2013, 10:34:18 PM (11 years ago)
Author:
chronos
Message:
  • Opraveno: Použití NULL hodnoty při práci s tabulkou Log a slovníkem.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/global_function.php

    r486 r499  
    255255    else $IP = addslashes($_SERVER['REMOTE_ADDR']);
    256256
    257   if(isset($User->Id)) $UserId = $User->Id;
    258     else $UserId = 0;
     257  if(!is_null($User->Id)) $UserId = $User->Id;
     258    else $UserId = 'NULL';
    259259  $Query = 'INSERT INTO `Log` ( `User` , `Type` , `Text` , `Date` , `IP` )
    260260   VALUES ('.$UserId.', '.$Type.', "'.addslashes($Text).'", NOW(), "'.$IP.'")';
Note: See TracChangeset for help on using the changeset viewer.