This forum is no longer open and is for reading/searching only.
Please use our new MachForm Community Forum instead.
MachForm Community Forums » MachForm 4
One entry per day
Started 9 years ago by clctv | 2 posts |
-
I know there is a way i can limit to one entry per IP address, but is there a way I can limit to one entry per IP address per day? Thank you
Posted 9 years ago # -
You can change the limit logic to allow the same IP on next day.
To do this edit includes/post-functions.php file and go to around line 1710, you will see these code :$query = "select count(id) total_ip from <code>".MF_TABLE_PREFIX."form_{$form_id}</code> where ip_address=? and <code>status</code>=1 " ;
then change the sql to
$query = "select count(id) total_ip from <code>".MF_TABLE_PREFIX."form_{$form_id}</code> where ip_address=? and <code>status</code>=1 and DATE_FORMAT(date_created,'%Y%m%d') = DATE_FORMAT(now(),'%Y%m%d') " ;
MachForm Support
Posted 9 years ago #
Reply
You must log in to post.