• I want to have a script populate latest posts on the home page by using tags such as (regions of service) to highlight certain areas that we serve? Is there a way to do this? or any work arounds?

    • This topic was modified 6 years, 9 months ago by aaronchakra.

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • This plugin should do it. there are detailed instructions on how to create a shortcode

    https://www.ads-software.com/plugins/display-posts-shortcode/

    Thread Starter aaronchakra

    (@aaronchakra)

    Is there a plug in that populates latest posts on the homepage based on the location of the visitor?

    Moderator bcworkz

    (@bcworkz)

    Maybe one of the ones listed at https://www.ads-software.com/plugins/search/geolocation/ ?

    Keep in mind geo-location by IP address is very unreliable. My current IP says I’m several hundred km from my actual location. Mobile locations are of course more accurate, but AFAIK are only available to mobile apps, not webpages.

    Thread Starter aaronchakra

    (@aaronchakra)

    What about this..

    Customer searches “Services in x suburb” They see pictures for that suburb and surrounding ones and a blurb from the blog page. Then they go to the home page and they see things tailored to what they searched and where they are?

    Moderator bcworkz

    (@bcworkz)

    So the user selects the preferred region? That’s good, as sometimes users are not located in the area they are interested in, even if IP location were accurate.

    I’d think you could find some sort of plugin that allows one to filter posts by a region taxonomy term. If not, a bespoke plugin wouldn’t be that complicated.

    You can preserve a user’s region preference between requests any number of ways. Pass an URL parameter, session variables, cookie values, transients, user meta.

    After determining the preference, the query for service posts can be modified through the “pre_get_posts” action hook.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Displaying latest posts for specific tags?’ is closed to new replies.