'; if (!$show_rating_security_image) { // we skip the security question $page2 = false; $c = "1"; $_SESSION['twg_key'] = 1; } // only vote once per session for one image; $ratingimage = $twg_album . $image; $alreadyVoted = false; if (isset($_SESSION['votedArray'])) { $alreadyVoted = in_array( $ratingimage, $_SESSION['votedArray']); } if ($rating == false && !$alreadyVoted) { echo $lang_rating_text; echo ''; } else if ($page2 && !$alreadyVoted) { echo $lang_rating_security . '

CAPTCHA IMAGE

' . $lang_rating_help . ''; echo ''; return; } else { if ($c && $_SESSION['twg_key'] == strtolower($c)) { if (!increaseVotesCount($twg_album, $image, $rating) || $alreadyVoted) { echo "
"; echo $lang_rating_message1 . "
 
" . $lang_rating_message2 . "
 
 
" ; } else { $_SESSION['votedArray'][] = $ratingimage; // we save that we voded already // send an email if set to true ! if ($send_notification_if_rating) { $submailheaders = "From: $youremail\n"; $submailheaders .= "Reply-To: $youremail\n"; if ($enable_email_sending) { $link = "http://" . get_server_name() . ":" . $_SERVER['SERVER_PORT'] . urldecode($twg_root) . "?twg_album=" . $album_enc . "&twg_show=" . $image_enc; @mail($admin_email, html_entity_decode ($notification_rating_subject), html_entity_decode (str_replace("\n", "\r\n", sprintf($notification_rating_text, $link)) . "\r\n\r\n" . $rating), $submailheaders); } } $_SESSION["actalbum"] = "LOAD NEW"; echo "
"; // "
" . $lang_rating_new . getVotesCount($twg_album, $image) . echo $lang_rating_message3 . "
 
" . $lang_rating_message2 . "
 
 
"; } } else { echo $lang_rating_message4 . "
"; echo '
CAPTCHA IMAGE

' . $lang_rating_help . ''; } if (isset($_GET["PHPSESSID"])) { $closescript = ""; } else { $closescript = ""; } echo ''; return; } echo'
'; ?>

  value="1" />
  value="2" />
  value="3" />
  value="4" />
  value="5" />