Skip to:
Content
Pages
Categories
Search
Top
Bottom

I need help urgently…please

  • Hi,
    I’m trying to create a buddy press component, I want to retrieve posts based on custom filed using meta_query of the get_posts word press functions from an ajax function in buddy press component ajax file,
    I wrote my $args as flowing:

    $args = array(

    ‘s’=>$keyword ,

    ‘post_type’ => ‘businesspost’,
    ‘post_status’ => array(‘publish’),
    ‘orderby’ => ‘post_date’,
    ‘showposts’=>10,

    ‘meta_query’ => array(
    array(‘key’ => ‘_offertype’, ‘value’ => ‘sellofer’
    ) )
    );

    If i delete the meta_query it gives posts fine, but when i add the meta query it gives nothing, I’m sure that my custom field key and value are correct.
    please some one helping me.

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘I need help urgently…please’ is closed to new replies.
Skip to toolbar