Search results / Gd listings shortcode

This topic contains 3 replies, has 2 voices, and was last updated by  Alex Rollin 3 years, 11 months ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #542627

    vivek
    Full Member
    Post count: 246

    Hi, is there a shortcode/widget to output the search results (NOT show Search bar) on a page, with pre-selected filters?

    Eg I have a CPT>Category as Tutors>Physics Tutors, and I have a custom field “Online classes available?” (key: online_classes) which is set Yes/No.

    In search bar i can set the cpt/category and select the custom field and get search results.

    However, I want to show these results not as a search results page, but as part of another non-GD page – just the listings, not the full search page (NOTE – i do not want a user search term input, it is just basis custom field value)

    This could be done using gd_listing shortcode also,if i was able to use custom field as a parameter in the shortcode as [gd_listings cpt= gd_tutors category=”Physics” online_classes=”Yes”]

    Any suggestions on how i can achieve this?

    thanks,
    Vivek

    #542711

    Alex Rollin
    Moderator
    Post count: 27815

    Hello,

    GD Listings is a query builder that can return many search results, but, not all, and there isn’t a shortcode specifically for returning search results.

    What you can do with GD Listings is create a sort that orders by your custom field, then show the first N of that query.

    #542729

    vivek
    Full Member
    Post count: 246

    Thanks, Alex.

    Is it also possible to use tags, as discussed in this thread?
    https://wpgeodirectory.com/support/topic/shortcode-for-gd-listings-sorted-by-custom-fields/

    So i can add a tag “Online available” in those listings and then use gd_listings shortcode to filter that?

    But i dont understand what is a tag “Title” and what is the “slug” – isnt tag just a word/phrase without spaces?

    thanks, Vivek

    #542888

    Alex Rollin
    Moderator
    Post count: 27815

    1, yes
    2, Try Online available

Viewing 4 posts - 1 through 4 (of 4 total)

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket