Which php files should I edit?

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

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

Open Support Ticket
  • Author
    Posts
  • #523770

    Manfred Van Ursel
    Expired Member
    Post count: 295

    Hi,

    We have a plugin called Restrict Content Pro.
    Whith it, we can restrict content to registered and premium users.

    We have to use some PHP tags to restrict contents, and we want to apply them on the Search Results page.

    Which templates are the ones that show the list/grid of results in the search results?
    We would like to affect those.

    (as a note, the plugin offers shortcodes that we should be able to use in the Search Page, which we already tried without any succes).

    Thanks,

    #523779

    Kor
    Moderator
    Post count: 16516

    Hi manfred,

    Thanks for your post. You can refer to this section of the documentation that explains more about customizing GD templates https://wpgeodirectory.com/docs-v2/faq/customizing/#templates

    #523845

    Manfred Van Ursel
    Expired Member
    Post count: 295

    Thanks, I’ll follow the guide, however, which is the theme’s path to the files that run the Search Results page? Thanks!

    #523863

    Kor
    Moderator
    Post count: 16516

    Hi Manfred Van Ursel,

    Thanks for your reply. Which theme are you using?

    #523878

    Manfred Van Ursel
    Expired Member
    Post count: 295

    Hi Kor, we are using the Divi Theme, and GD as a plugin.

    #527127

    Manfred Van Ursel
    Expired Member
    Post count: 295

    So, our goal would be to make edits to the file that is responsible of showing the Search Results.

    As we aren’t using a theme from you (but the Divi theme), I assume that file would be in the plugin?

    Or is it a Divi file I have to edit?

    ideally, we would be able to add some conditional statements on the different content elements that make the search results page, that is:

    – if user is subscriber, show map with bubbles, and show results
    – if user is not subscriber, show ma with bubbles, but do not show results
    – etc (things like that)

    Thanks, for your help.

    #527130

    Alex Rollin
    Moderator
    Post count: 27815

    Search results are shown with the gd_loop.
    The search query is in includes/class-geodir-query.php

    In order to take the map apart and put it back together you will need the GD Map widget in the templates folder.

    It might be a good idea to see what you can achieve just editing the GD Search template, the WP Page that is.

    https://wpgeodirectory.com/docs-v2/templates/search/

    #527131

    Alex Rollin
    Moderator
    Post count: 27815
    This reply has been marked as private.
Viewing 8 posts - 1 through 8 (of 8 total)

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

Open Support Ticket