time()) { $errors = true; $antispam_error = $lang["expiredantispam"]; } elseif (!hook('replaceantispam_check') && !verify_antispam($spamcode, $usercode, $spamtime)) { $errors = true; $antispam_error = $lang["requiredantispam"]; } if ($errors) { exit(escape($antispam_error)); } } $messagetext = getval("messagetext", ""); $templatevars['url'] = $baseurl . "/?r=" . $ref; $templatevars['fromusername'] = ($userfullname == "" ? $username : $userfullname); $templatevars['resourcename'] = $imagename; $templatevars['emailfrom'] = $useremail; $subject = $templatevars['fromusername'] . $lang["contactadminemailtext"]; $templatevars['message'] = $messagetext; $message = $templatevars['fromusername'] . ($useremail != "" ? " (" . $useremail . ")" : "") . $lang["contactadminemailtext"] . "\n\n" . $messagetext . "\n\n" . $lang["clicktoviewresource"] . "\n\n" . $templatevars['url']; $notification_message = $templatevars['fromusername'] . ($useremail != "" ? " (" . $useremail . ")" : "") . $lang["contactadminemailtext"] . "\n\n" . $messagetext . "\n\n" . $lang["clicktoviewresource"]; global $watermark; $templatevars['thumbnail'] = get_resource_path($ref, true, "thm", false, "jpg", $scramble = -1, $page = 1, ($watermark) ? (($access == 1) ? true : false) : false); if (!file_exists($templatevars['thumbnail'])) { $templatevars['thumbnail'] = "../gfx/no_preview/default.png"; } # Build message and send. $admin_notify_emails = array(); $admin_notify_users = array(); $notify_users = get_notification_users("RESOURCE_ADMIN"); foreach ($notify_users as $notify_user) { get_config_option(['user' => $notify_user['ref'], 'usergroup' => $notify_user['usergroup']], 'user_pref_resource_notifications', $send_message); if (!$send_message) { continue; } get_config_option(['user' => $notify_user['ref'], 'usergroup' => $notify_user['usergroup']], 'email_user_notifications', $send_email); if ($send_email && $notify_user["email"] != "") { $admin_notify_emails[] = $notify_user['email']; } else { $admin_notify_users[] = $notify_user["ref"]; } } foreach ($admin_notify_emails as $admin_notify_email) { send_mail($admin_notify_email, $subject, unescape($message), $applicationname, $email_from, "emailcontactadmin", $templatevars, $applicationname); } if (count($admin_notify_users) > 0) { message_add($admin_notify_users, $notification_message, $templatevars['url']); } exit("SUCCESS"); } if ($insert == "") { # Fetch search details (for next/back browsing and forwarding of search params) $search = getval("search", ""); $order_by = getval("order_by", "relevance"); $offset = getval("offset", 0, true); $default_sort_direction = "DESC"; if (substr($order_by, 0, 5) == "field") { $default_sort_direction = "ASC"; } $sort = getval("sort", $default_sort_direction); $archive = getval("archive", 0, true); include "../../include/header.php"; ?>

" alt="" class="Picture"/>
<?php echo $imagename ?>