ValidateLogin('none,sales,antibodies', "index.html", " to submit antibodies"); $pageheader = new BannerMenus_cellbio($link, $DB_USER_TABLE, $path); $title = 'Submit antibody :: ProteinSimple'; $description = ''; /* The page's main menu section - 'about' 'products' 'applications' 'learn' 'support' 'contact' or 'shop' */ $section = 'learn'; // Custom page code global $HTTP_POST_VARS; global $HTTP_GET_VARS; CleanHTTPVars(); $formname = "regform"; $thefunction = $HTTP_POST_VARS["thefunction"]; $captcha = $HTTP_POST_VARS["captcha"]; $antibody_userid = 0; $id = GetParam0("id"); if ($id > 0) { $query = "SELECT id, live, userid, assay, performance, protein, vendor, product_code, protein_isoform, species, cell_model, separated_by, dilutions, apparent_mw, submitted_by, contact, keywords FROM cellbio_antibodies WHERE id=$id;"; $result = mysql_query($query, $link); $rows = mysql_num_rows($result); if ($rows > 0) { $antibody_userid = mysql_result($result, 0, "userid"); $protein = mysql_result($result, 0, "protein"); $vendor = mysql_result($result, 0, "vendor"); $product_code = mysql_result($result, 0, "product_code"); $protein_isoform = mysql_result($result, 0, "protein_isoform"); $species = mysql_result($result, 0, "species"); if ($species != 'rabbit polyclonal' && $species != 'rabbit monoclonal' && $species != 'mouse monoclonal') { $species_other = $species; $species = "other"; } $cell_model = mysql_result($result, 0, "cell_model"); $dilutions = mysql_result($result, 0, "dilutions"); $apparent_mw = mysql_result($result, 0, "apparent_mw"); $performance = mysql_result($result, 0, "performance"); if ($performance != 'Specific Antibody' && $performance != 'Clean Peak Profile Specific Antibody' && $performance != 'Complex Peak Profile Non-Specific Antibody' && $performance != 'Many Peaks Observed' && $performance != 'No Profile Observed') { $performance_other = $species; $performance = "other"; } $submitted_by = mysql_result($result, 0, "submitted_by"); $separated_by = mysql_result($result, 0, "separated_by"); $contact = mysql_result($result, 0, "contact"); } } else { $protein = $HTTP_POST_VARS["protein"]; $vendor = $HTTP_POST_VARS["vendor"]; $product_code = $HTTP_POST_VARS["product_code"]; $protein_isoform = $HTTP_POST_VARS["protein_isoform"]; $species = $HTTP_POST_VARS["species"]; $species_other = $HTTP_POST_VARS["species_other"]; $cell_model = $HTTP_POST_VARS["cell_model"]; $dilutions = $HTTP_POST_VARS["dilutions"]; $apparent_mw = $HTTP_POST_VARS["apparent_mw"]; $performance = $HTTP_POST_VARS["performance"]; $performance_other = $HTTP_POST_VARS["performance_other"]; $submitted_by = $HTTP_POST_VARS["submitted_by"]; $separated_by = $HTTP_POST_VARS["separated_by"]; $contact = $HTTP_POST_VARS["contact"]; } $dbrecord = new DBRecord($link, "../", $formname); // If a reCAPTCHA form was submitted. This replaces '$thefunction == "reg"' as the primary form-submission check. if (isset($_POST["g-recaptcha-response"])) { // reCAPTCHA code to check the form response. $secretkey = '6LfO3BwUAAAAABERH0zxa1Fis8L4XSWpIod7pE7D'; $response = file_get_contents("https://www.google.com/recaptcha/api/siteverify?secret=$secretkey&response=" . $_POST['g-recaptcha-response']); $responseData = json_decode($response); // If reCAPTCHA is verified, submit the form. if ($responseData->success) { // This is the original form submission check. if ( !empty($thefunction) && $thefunction == "reg" ) { $dbrecord = Register($link, $dbrecord, $captcha, $userid, $id); } } // reCAPTCHA detected a problem, post error message. else { $dbrecord->c_errors["message"] = "The reCAPTCHA box indicated an error. Please try again!"; } } $prefix = " "; $suffix = ""; // End custom page code /* Start page */ page_head_start($title, $description); // Load any additional CSS and JS files here // Required for reCAPTCHA V2 widget. See below. ?>
page_body_header($section,$userid); page_body_content_start(); // Main content area start (for use with right sidebar) page_body_content_main_with_right_sidebar_start(); ?>GetFieldError("message") . $suffix ?>
0 && $antibody_userid != $userid) { ?>Unauthorized access! Please contact tech support.
ProteinSimple very much appreciates your collaboration.