wp_query Classipress
Good morning,
I am trying to accomplish a custom searchform with multi-level fields. I am using the wordpress categories to achieve the multi-level part.
To do this, I first developed everything on theme TwentyTwelve, and once it was working, I proceeded to place it on Classipress.
First, I will implement it on a parent, and when it works on a parent, I will proceed to a child theme.
I already have my searchform developed, it also has de multi-level (3 levels) working correctly and other custom fields. (Please see next image).
searchform.jpg
NOTE: If anyone is interested in the code, just tell me and I will post it...
NOTE 2: I am not styling it yet... after it works correctly, I will put it "nice"
NOTE 3: for the multi-level to work, it was necessary to comment wp_enqueue_script( 'selectbox................. in the file /includes/theme-enqueue.php
and comment
Code:
/* style the select dropdown menus */
/* $('select').selectBox({
menuTransition: 'fade', // default, slide, fade
menuSpeed: 'fast'
}); */
in includes/theme-scripts.
js
Now what I'm missing is the query modification.
This is the coding on TwentyTwelve for that part:
Code:
$args = array(
cat => $cat1,
'meta_query' => array(
array(
'key' => 'Ano',
'value' => array( $ano_desde, $ano_hasta ),
'type' => 'numeric',
'compare' => 'BETWEEN'
),
array(
'key' => 'Precio',
'value' => array( $precio_desde, $precio_hasta ),
'type' => 'numeric',
'compare' => 'BETWEEN'
),
array(
'key' => 'Ubicacion',
'value' => $ubicacion,
'compare' => 'LIKE'
)
)
);
$the_query = new WP_Query( $args );
Could someone please tell me:
1. Is it possible to use wp_query in Classipress?
2. If answer 1. is yes, where or how can I do this?
Any help is greatly appreciated.
Thanks in advance.