Setting Location In Navigation Bar

This topic contains 19 replies, has 4 voices, and was last updated by  Stiofan O’Connor 6 years, 3 months ago.

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

Open Support Ticket
  • Author
    Posts
  • #414536

    Garrick Soohoo
    Free User
    Post count: 37

    I have the “pick location” set up in the navigation bar. However it resets back to pick location anytime I go to a page that isn’t built in to geodirectory. Obviously that is not a good design. You should set your location and have it show correct on any page. How can I get the location to stay when looking at a blog post or going to my buddpress profile (the geodirectory integration)?

    http://www.staging.classicalcitizens.com/

    If it can’t get working properly on other pages, how can you disable the reset? That way it will still show the correct city name on other pages even if not having a function.

    #414537

    Joy
    Buyer
    Post count: 1076

    I think it might be addressed by this setting: Dashboard > Geodirectory > Multilocation > Homepage should go to: Current location page

    #414538

    Garrick Soohoo
    Free User
    Post count: 37

    That is correct, but you are missing the point. When you set a location, current location page, you get directed to that page. If after that page you go anywhere else, it resets the location back to “pick location”. I want to pick a location and have it stay set.

    #414539

    Joy
    Buyer
    Post count: 1076

    Hmmm, I see what you’re saying. I honestly didn’t even notice this. But looking at my own site I see the same behavior. I’ll watch this post and wait to see what the devs say.

    Thanks for highlighting this issue.

    #414553

    Guust
    Moderator
    Post count: 29970

    WP pages have no idea what location you set, so that info is lost.
    One option is to use GD pages only, but I guess that is quite restrictive.
    I’ll get the developers to have a look, if I remember correctly there is some coding work around.

    Thanks

    #414554

    Garrick Soohoo
    Free User
    Post count: 37

    Is there a way to make regular WP pages as part of the GD pages so the location settings in the widgets also work?

    #414594

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    We used to work it that way and has nothing but problems with caching. If you set location X on a standard page then it will show different info for different people/search engines, caching etc. It took us a long time to get away from this and we will never go back 🙂

    You have the location page for each locations, whats wrong with using that?

    Stiofan

    #414634

    Garrick Soohoo
    Free User
    Post count: 37

    The whole point is to get each location page to look like http://www.staging.classicalcitizens.com/ with the places, reviews, and events to be for that location. Is that possible with geodirectory?

    #414659

    Guust
    Moderator
    Post count: 29970

    Each location page has a header, top section, 3 columns, a bottom section and a footer, see https://wpgeodirectory.com/docs/layout/#directory

    So set each column to about 32% width and add the same widgets to the columns as you used on the homepage of your site.

    Thanks

    #414733

    Garrick Soohoo
    Free User
    Post count: 37

    Is there a way to make the title & meta variables work in the widget body areas?

    I know https://wpgeodirectory.com/docs/gd-core-plugin-titles-metas/ has a way to make the title & meta variables show in the widget titles, but was wondering about getting it to work content/text area.

    #414799

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    Not tested but you could try “the_content” filter.

    Stiofan

    #414826

    Garrick Soohoo
    Free User
    Post count: 37

    Ok. Last question.

    I am ultimately trying to customize the page for different locations with places, reviews, and events to be for that location page. It’s apparent I have to use the widget area of geodirectory plugin for location filtering to work properly….

    so how would I go about having a background image change for different cities? Is there a way to add a css class based on location or category within geodirectory? Is there a different page-id created for different pages created by geodirectory.

    Essentially how can I style
    http://www.staging.classicalcitizens.com/location/united-states/california/aliso-viejo/
    and
    http://www.staging.classicalcitizens.com/location/united-states/california/anaheim/
    differently since I have to use the widget area to add the page layout?

    #414852

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    You can add images to the locations settings, you can then get them with

    
    
    $seo = geodir_get_location_seo();
                if (isset($seo->seo_image_tagline) && $seo->seo_image_tagline) {
                    $sub_title = __($seo->seo_image_tagline, 'geodirlocation');
                }
                if (isset($seo->seo_image) && $seo->seo_image) {
                    $full_image_url = wp_get_attachment_image_src($seo->seo_image, 'full');
                }

    Hope that helps.

    Stiofan

    #414921

    Garrick Soohoo
    Free User
    Post count: 37

    I don’t understand what you sent. Where/how is that implemented?

    Thank you for your patience.

    #414922

    Garrick Soohoo
    Free User
    Post count: 37

    And with your response, does that mean css can’t be used to style individual locations/categories then?

Viewing 15 posts - 1 through 15 (of 20 total)

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

Open Support Ticket