View Single Post
Old September 8th, 2008, 04:02 PM   #1 (permalink)
CeBra
Member
Verified Customer
 
Join Date: Sep 2006
Location: Bonn - Germany
Posts: 94
Change upload limit from 24 hours to "real" days

Hi

my users complain about the fact that the upload limit is based on 24hrs rather than on real daycounts. I have searched the support forum and found a thread ( hack) where a change in uploadphoto.php from


if ( $User['uploadlimit'] > 0 ) {
$upload = ppmysql_query("SELECT COUNT(*) FROM {$Globals['pp_db_prefix']}photos WHERE userid={$User['userid']} AND date > UNIX_TIMESTAMP( DATE_SUB(NOW(), INTERVAL 24 HOUR) )", $link);


to

if ( $User['uploadlimit'] > 0 ) {
$upload = ppmysql_query("SELECT COUNT(*) FROM
{$Globals['pp_db_prefix']}photos WHERE userid={$User['userid']} AND
FROM_UNIXTIME(date, '%Y-%m-%d') = CURDATE()", $link);


should solve the issue.

But somehow it doesn't work.

Now I am not expert enough to see what is wrong about the statement, but I would really love to change things so users are happy again

Any help is greatly appreciated!
CeBra is offline   Reply With Quote