Forum Replies Created

Viewing 1 replies (of 1 total)
  • Thread Starter agovea

    (@agovea)

    Thank you very much for your reply,

    try the code and does not work, place it in functions and use get_search_filter

    functions.php

    add_filter( 'get_search_query', 'uwpqsf_var', 20, 1 );
    function uwpqsf_var($s){
     if(is_search() && isset($_GET['s']) && $_GET['s'] == 'uwpsfsearchtrg' && isset($_GET['uformid']) ){
          if(isset($_GET['taxo'])){
             foreach($_GET['taxo'] as $v){
    	    if(isset($v['term'])){
    	       if($v['term'] == 'uwpqsftaxoall'){
    
    	       }else{
    		      $termname = get_term_by('slug',$v['term'],$v['name']);
    		      $var[] = $termname->name;
    		     }
    	    }
             }
             $return = '';
    	   if(!empty($var)){
              	 $return = implode(' | ', $var);
               }
             return $return;
          }
      }
    }

    search.php

    <?php echo get_search_filter (); ?>

Viewing 1 replies (of 1 total)