1, 'text' => TEXT_PENDING_APPROVAL); $status_list[] = array('id' => 2, 'text' => TEXT_APPROVED); if (zen_not_null($action)) { switch ($action) { case 'setflag': if (isset($_POST['flag']) && ($_POST['flag'] == 1 || $_POST['flag'] == 0)) { zen_set_reviews_status($_GET['rID'], $_POST['flag']); } zen_redirect(zen_href_link(FILENAME_REVIEWS, (isset($_GET['page']) ? 'page=' . $_GET['page'] . '&' : '') . (isset($_GET['status']) ? 'status=' . $_GET['status'] . '&' : '') . 'rID=' . $_GET['rID'], 'NONSSL')); break; case 'deleteconfirm': // demo active test if (zen_admin_demo()) { $_GET['action']= ''; $messageStack->add_session(ERROR_ADMIN_DEMO, 'caution'); zen_redirect(zen_href_link(FILENAME_CONTACTUS, (isset($_GET['page']) ? 'page=' . $_GET['page'] . '&' : '') . (isset($_GET['status']) ? 'status=' . $_GET['status'] : ''))); } $id = zen_db_prepare_input($_POST['cID']); $db->Execute("delete from contactus where id = '" . (int)$id . "'"); zen_redirect(zen_href_link(FILENAME_CONTACTUS, (isset($_GET['page']) ? 'page=' . $_GET['page'] . '&' : '') . (isset($_GET['status']) ? 'status=' . $_GET['status'] : ''))); break; } } ?> > <?php echo TITLE; ?>
Execute("select id,name,email,date_add,comment from contactus where id = '" . (int)$cID . "'"); $cInfo_array = array_merge($contactus->fields); $cInfo = new objectInfo($cInfo_array); } ?> $cInfo->name); $contents = array('form' => zen_draw_form('reviews', FILENAME_CONTACTUS, (isset($_GET['page']) ? 'page=' . $_GET['page'] . '&' : '') . (isset($_GET['status']) ? 'status=' . $_GET['status'] . '&' : '') . 'action=deleteconfirm') . zen_draw_hidden_field('cID', $cInfo->id)); $contents[] = array('text' => '
' . $cInfo->email . ''); $contents[] = array('align' => 'center', 'text' => '
' . zen_image_submit('button_delete.gif', IMAGE_DELETE) . ' ' . zen_image_button('button_cancel.gif', IMAGE_CANCEL) . ''); break; default: if (isset($cInfo) && is_object($cInfo)) { $heading[] = array('text' => '' . $cInfo->id . ''); $contents[] = array('align' => 'center', 'text' => '' . zen_image_button('button_delete.gif', IMAGE_DELETE) . ' ' . ' ' . zen_image_button('button_details.gif', IMAGE_DETAILS) . ''); $contents[] = array('text' => ' ' . zen_date_short($cInfo->date_add)); $contents[] = array('text' => ' ' . $cInfo->name); $contents[] = array('text' => ' ' . $cInfo->email); $contents[] = array('text' => ' ' . $cInfo->comment); } break; } if ( (zen_not_null($heading)) && (zen_not_null($contents)) ) { echo ' ' . "\n"; } ?>
name; ?>
email; ?>
date_add); ?>

comment; ?>
Execute($contactus_query_raw); $check_count=1; if ($check_page->RecordCount() > MAX_DISPLAY_SEARCH_RESULTS) { while (!$check_page->EOF) { if ($check_page->fields['id'] == $_GET['cID']) { break; } $check_count++; $check_page->MoveNext(); } $_GET['page'] = round((($check_count/MAX_DISPLAY_SEARCH_RESULTS)+(fmod_round($check_count,MAX_DISPLAY_SEARCH_RESULTS) !=0 ? .5 : 0)),0); } else { $_GET['page'] = 1; } } // $reviews_query_raw = "select reviews_id, products_id, date_added, last_modified, reviews_rating, status from " . TABLE_REVIEWS . " order by date_added DESC"; $contact_split = new splitPageResults($_GET['page'], MAX_DISPLAY_SEARCH_RESULTS, $contactus_query_raw, $reviews_query_numrows); $contactus = $db->Execute($contactus_query_raw); while (!$contactus->EOF) { if ((!isset($_GET['cID']) || (isset($_GET['cID']) && ($_GET['cID'] == $contactus->fields['id']))) && !isset($cInfo)) { $contactusid = $db->Execute("select id,name,email,comment from contactus where id = '" . (int)$_GET['cID'] . "'"); $cid_info = $contactusid->fields; if($cid_info){ $cInfo_array = array_merge($contactus->fields, $cid_info); } else{ $cInfo_array =$contactus->fields; } $cInfo = new objectInfo($cInfo_array); } if (isset($cInfo) && is_object($cInfo) && ($contactus->fields['id'] == $cInfo->id) ) { echo ' ' . "\n"; } else { echo ' ' . "\n"; } ?> MoveNext(); } ?>
Id Name Email Comment Date  
fields['id']; ?> fields['name']; ?> fields['email']; ?> fields['comment']; ?> fields['date_add']); ?> fields['id'] == $cInfo->id) ) { echo zen_image(DIR_WS_IMAGES . 'icon_arrow_right.gif'); } else { echo '' . zen_image(DIR_WS_IMAGES . 'icon_info.gif', IMAGE_ICON_INFO) . ''; } ?> 
display_count($reviews_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $_GET['page'], TEXT_DISPLAY_NUMBER_OF_REVIEWS); ?> display_links($reviews_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $_GET['page'], zen_get_all_get_params( array( 'page', 'rID' ))); ?>
' . "\n"; $box = new box; echo $box->infoBox($heading, $contents); echo '