Advertisement
jegtheme

search-job-filter.php

Jun 2nd, 2016
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 6.56 KB | None | 0 0
  1. <div class="col-md-3">
  2.     <div class="block-section-sm side-right">
  3.  
  4.         <form class="search-filter">
  5.             <div class="result-filter">
  6.                 <div class="filter-item search-keyword-filter">
  7.                     <h5 class="no-margin-top font-bold margin-b-20 "><?php _e('Search Keyword', 'jobplanet-plugin'); ?></h5>
  8.                     <div class="form-group">
  9.                         <input id="keyword" name="keyword" value="<?php echo isset($_REQUEST['keyword']) ? $_REQUEST['keyword'] : ''; ?>" placeholder="<?php _e('Search Keyword', 'jobplanet-plugin'); ?>" class="form-control" type="text">
  10.                     </div>
  11.                 </div>
  12.  
  13.                 <div class="filter-item location-filter">
  14.                     <h5 class="no-margin-top font-bold margin-b-20 "><?php _e('Location', 'jobplanet-plugin'); ?></h5>
  15.                     <div class="form-group location-form">
  16.                         <?php
  17.                         $location = isset($_REQUEST['place']) ? $_REQUEST['place'] : '';
  18.                         ?>
  19.                         <input class="form-control location-autocomplete filter-location location" name="place" placeholder="<?php _e('preferred job location', 'jobplanet-plugin'); ?>" value="<?php echo esc_attr($location); ?>">
  20.                     </div>
  21.                 </div>
  22.  
  23.                 <div class="filter-item contract-type-filter">
  24.                     <h5 class="no-margin-top font-bold margin-b-20 "><?php _e('Contract Type', 'jobplanet-plugin'); ?></h5>
  25.                     <div class="form-group">
  26.                         <?php
  27.                         $types = jeg_get_job_type();
  28.                         if($types) {
  29.                             foreach($types as $type) {
  30.                                 $checked = '';
  31.                                 if(isset($_REQUEST['type'])) {
  32.                                     if($_REQUEST['type'] === $type['value']) {
  33.                                         $checked = 'checked';
  34.                                     }
  35.                                 } else {
  36.                                     $checked = 'checked';
  37.                                 }
  38.                                 ?>
  39.                                 <div class="checkbox contract-type flat-checkbox">
  40.                                     <label>
  41.                                         <input type="checkbox" name="type[]" value="<?php echo esc_attr($type['value']) ?>" <?php echo esc_attr($checked); ?>>
  42.                                         <span class="fa fa-check"></span>
  43.                                         <?php echo esc_attr($type['label']) ?>
  44.                                     </label>
  45.                                 </div>
  46.                                 <?php
  47.                             }
  48.                         }
  49.                         ?>
  50.                         <input type="hidden" name="type[]" value="">
  51.                     </div>
  52.                 </div>
  53.  
  54.                 <div class="filter-item category-filter">
  55.                     <h5 class="no-margin-top font-bold margin-b-20 "><?php _e('Categories', 'jobplanet-plugin'); ?></h5>
  56.                     <div class="form-group">
  57.                         <select name="categories" multiple class="chosen-select form-control categories" data-placeholder="<?php _e('Choose Category', 'jobplanet-plugin'); ?>">
  58.                             <?php
  59.                                 $categories = jeg_get_job_category();
  60.                                 if($categories) {
  61.                                     foreach($categories as $category) {
  62.                                         $selected = ( isset($_REQUEST['categories']) && $_REQUEST['categories'] == $category['value'] ) ? "selected=selected" : "";
  63.                                         ?>
  64.                                         <option value="<?php echo esc_attr($category['value']) ?>" <?php echo $selected ?>><?php echo esc_attr($category['label']) ?></option>
  65.                                         <?php
  66.                                     }
  67.                                 }
  68.                             ?>
  69.                         </select>
  70.                     </div>
  71.                 </div>
  72.  
  73.                 <div class="filter-item salary-range-filter" style="display: none;">
  74.                     <h5 class="no-margin-top font-bold margin-b-20"><?php _e('Salary Range', 'jobplanet-plugin'); ?></h5>
  75.                     <select class="form-control chosen-select salary-range" name="salary_range" data-placeholder="<?php _e('Salary Range', 'jobplanet-plugin'); ?>">
  76.                         <option></option>
  77.                         <option value="hourly"><?php _e('Hourly', 'jobplanet-plugin'); ?></option>
  78.                         <option value="weekly"><?php _e('Weekly', 'jobplanet-plugin'); ?></option>
  79.                         <option value="monthly"><?php _e('Monthly', 'jobplanet-plugin'); ?></option>
  80.                         <option value="yearly"><?php _e('Yearly', 'jobplanet-plugin'); ?></option>
  81.                     </select>
  82.                 </div>
  83.  
  84.                 <div class="filter-item salary-filter"  style="display: none;">
  85.                     <h5 class="no-margin-top font-bold margin-b-20 "><?php _e('Salary Filter', 'jobplanet-plugin'); ?></h5>
  86.                     <div class="jobplanet_price_slider">
  87.                         <div class="price_label">
  88.                             <?php _e('Salary :', 'jobplanet-plugin'); ?> <span class="from"></span> &mdash; <span class="to"></span>
  89.                         </div>
  90.                         <div class="price_slider"></div>
  91.                         <div class="price_slider_amount">
  92.                             <input type="hidden" id="min_price" name="min_salary" value="" data-min="<?php echo esc_attr(jeg_get_lowest_salary()) ?>" placeholder="<?php _e('Min price', 'jobplanet-plugin'); ?>" />
  93.                                 <input type="hidden" id="max_price" name="max_salary" value="" data-max="<?php echo esc_attr(jeg_get_higest_salary()) ?>" placeholder="<?php _e('Max price', 'jobplanet-plugin'); ?>" />
  94.                             <div class="clear"></div>
  95.                         </div>
  96.                     </div>
  97.                 </div>
  98.                 <input type="hidden" name="paged" class="paged" value="<?php echo get_query_var('paged') ? get_query_var('paged') : 1 ?>">
  99.                 <input type="hidden" name="jobplanet_nonce" value="<?php echo esc_attr( wp_create_nonce('jobplanet') ); ?>"/>
  100.                 <input type="hidden" name="action" value="search_job_ajax">
  101.             </div>
  102.         </form>
  103.     </div>
  104. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement