diff options
author | pb1dft <pb1dft@ampache> | 2006-10-28 01:23:00 +0000 |
---|---|---|
committer | pb1dft <pb1dft@ampache> | 2006-10-28 01:23:00 +0000 |
commit | 5038eb20d7322af95d1fef7035f6d533b49c25a6 (patch) | |
tree | 38738e76d35b3e8c7c115a517d721aa6feaf445d /lib/ui.lib.php | |
parent | 5db7a0e53c7a9e415254bbda05496e31cf2f699c (diff) | |
download | ampache-5038eb20d7322af95d1fef7035f6d533b49c25a6.tar.gz ampache-5038eb20d7322af95d1fef7035f6d533b49c25a6.tar.bz2 ampache-5038eb20d7322af95d1fef7035f6d533b49c25a6.zip |
minor glitch in ip_history fixed
Diffstat (limited to 'lib/ui.lib.php')
-rw-r--r-- | lib/ui.lib.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/ui.lib.php b/lib/ui.lib.php index dffe38fd..a24b1ce0 100644 --- a/lib/ui.lib.php +++ b/lib/ui.lib.php @@ -158,8 +158,9 @@ function show_users () { function show_ip_history (){ $dbh = dbh(); - $date = time() - (86400*conf('user_ip_cardinality')); - $sql = "SELECT ip,date FROM ip_history where user = '$_REQUEST[user]' and date >= '$date' ORDER BY date DESC"; + if (conf('user_ip_cardinality')) { $cardinality = conf('user_ip_cardinality'); } else { $cardinality = '42'; } + $date = time() - (86400*$cardinality); + $sql = "SELECT ip,date FROM ip_history where user = '$_REQUEST[user]' and date >= '$cardinality' ORDER BY date DESC"; $db_results = mysql_query($sql, $dbh); show_box_top(); |