• I’m using Hidden voting type and I would like to hold a photo contest where a person can only vote on one picture in the entire contest therefore in viewimg.php, for email_check i’d like it not to consider img_id but rather just do an email compare.

    Is this possible?

Viewing 1 replies (of 1 total)
  • Plugin Author frekel

    (@frekel)

    This is possible… change the follwing:

    viewimg.php on line 358:
    $email_check = (int) $wpdb->get_var( $wpdb->prepare( "SELECT vote FROM ".$wpdb->prefix."photocontest_votes WHERE img_id= %d AND voter_email = %s AND voter_email!=''", $img_id , $emailadres) );

    to

    $email_check = (int) $wpdb->get_var( $wpdb->prepare( "SELECT vote FROM ".$wpdb->prefix."photocontest_votes WHERE voter_email = %s AND voter_email!=''", $emailadres) );

    Note that when you create a new contest, people won’t be able to vote again!!

    (This is a quick fix ??

    If you want a permanent solution, mail me (my email is in the readme file!)

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: PhotoContest Plugin] Allow only 1 vote per contest’ is closed to new replies.