<input id="deactivate_users" type="submit" class="button" value="تعطيل" style="background:gray; margin-top:0;"> <input id="activate_users" type="submit" class="button" value="تفعيل" style="margin-top:0;"> </div> <form id="users_form"> <table dir="rtl"> <thead> <tr> <th width="40"><input type="checkbox" check="users" name="all"></th> <th width="100">رقم العضوية</th> <th width="">البريد الاليكترونى</th> <th width="">الحالة</th> </tr> </thead> <tbody id="users_body"> <?php echo empty($users) ? '<tr><td colspan="4">لا يوجد عضويات</td></tr>' : Temp::users_container_rows($users); ?> </tbody> </table> </form> <input type="hidden" name="users_page" value="1"> <input type="hidden" name="users_total" value="<?php echo $total_users; ?> "> <div id="users_more"> <?php if ($total_users > 18) { ?> <input id="users_button" type="submit" value="المزيد"> <?php
public function search_cp() { if (Login::get_instance()->check_login() == 'valid') { $user_data = Register::get_instance()->get_current_user(); if ($user_data['status'] != 10) { exit; } if ($_POST) { if ($_POST['type'] == 'users') { if (is_numeric($_POST['value'])) { $settings['id'] = intval($_POST['value']); } else { if (Validation::email($_POST['value'])) { $settings['email'] = addslashes($_POST['value']); } else { echo ''; exit; } } $users = Register::get_instance()->get_user($settings); echo empty($users) ? '' : Temp::users_container_rows($users); } else { if ($_POST['type'] == 'ads') { if (is_numeric($_POST['value'])) { $settings['id'] = intval($_POST['value']); } else { $settings['words'] = addslashes($_POST['value']); } if (empty($_POST['value'])) { echo ''; exit; } $settings['limit'] = 'no'; $ads = ads::load_ads(0, $settings); echo empty($ads) ? '' : Temp::ad_container_rows($ads); } else { if ($_POST['type'] == 'clinics') { if (is_numeric($_POST['value'])) { $settings['id'] = intval($_POST['value']); } else { $settings['words'] = addslashes($_POST['value']); } if (empty($_POST['value'])) { echo ''; exit; } $settings['limit'] = 'no'; $clinics = ads::load_clinics($settings); echo empty($clinics) ? '' : Temp::ad_container_rows($clinics, 2); } } } } } }