Changeset 51 for branches/old/index.php


Ignore:
Timestamp:
Feb 20, 2015, 9:21:01 AM (10 years ago)
Author:
chronos
Message:
  • Modify: If measure not found then use default one.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/old/index.php

    r50 r51  
    156156    }
    157157$Output .= '<br>';
     158
     159$Result = $Database->select('measure', 'id', '(Enabled=1) AND ((PermissionView="all") OR (PermissionView="'.gethostbyaddr($_SERVER['REMOTE_ADDR']).'")) WHERE Id='.$_SESSION['Measure']);
     160if($Result->num_rows == 0) $_SESSION['Measure'] = $Config['DefaultVariables']['Measure'];
    158161
    159162$Output .= '<strong>Graf:</strong><br>';
Note: See TracChangeset for help on using the changeset viewer.