• Resolved trinidadr

    (@trinidadr)


    Im current using the following shortcode:
    [shortcode-weather-atlas city_selector=2372139 background_color=”transparent” text_color=”#414141″ sunrise_sunset=0 daily=0 detailed_forecast=1 current=0 city_selector_toggle=1]

    It is failing to display the toggle (hamburger menu). It is not even in the source.

    The widget does work on the sidebars with the toggle available using the same params as the shortcode.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Weather Atlas

    (@weatheratlas)

    Hi trinidadr,

    Yes, you’re right. (It’s not a bug).

    If a widget is placed using a shortcode, the toggle option (for overriding a city) doesn’t appear.
    The shortcode is (mostly) used for placing a widget (or more) on one page, usually within a (related) text, and therefore toggle is unneeded. (And, therefore, we’ve removed an unneeded feature and unneeded code).

    Thread Starter trinidadr

    (@trinidadr)

    Thanks for the quick reply!

    This is the one feature your plugin has over others and the shortcode needs it. 🙂

    The user is choosing the city he/she is in and placement on the page is irrelevant. For exampl, I have this added to a Page post; due to design restraints, this page doesn’t use sidebar widgets. This forces me to use the shortcode version.

    Plugin Author Weather Atlas

    (@weatheratlas)

    OK, point taken.

    But consider this:
    Webmaster uses multiple widgets on one page.
    What would happen if a user changes city on one widget? (the cookie remembers city)
    All widgets would show the same city.
    (Tha same thing would happen with sidebars, but having multiple widgets on sidebar or footer is unlikely)

    Thread Starter trinidadr

    (@trinidadr)

    Sounds like you have the right questions, but not the answers 🙂

    1) What would happen if a user changes city on one widget? (the cookie remembers city)
    A: You can add parameters to the cookie by widget ID.

    2) The same thing would happen with sidebars, but having multiple widgets on sidebar or footer is unlikely
    B: I would argue that having multiple widgets is more likely as WP admin might place different widgets on different sidebars and, arguably, they might want the same city.

    This would be solved by adding a plugin toggle option to “Use same city for all widgets” or “Use unique city settings per widget”; something of that sort.

    Thanks again for the quick reply.

    Thread Starter trinidadr

    (@trinidadr)

    Just wanted to post an update of a possible solution in case it might help others.

    Use AMR Shortcode Any Widget
    https://wordpress.org/plugins/amr-shortcode-any-widget/

    It allows you to clone a widget into a shortcode you can use on any Page or Post.

    Enjoy.

    Plugin Author Weather Atlas

    (@weatheratlas)

    Hi,

    if it’s not complicated set up, you and other webmasters can use AMR Shortcode Any Widget to solve your issue.

    As for other pieces of advice, at the moment we’d like to KISS.
    There’s already enough options in settings, and more (more important than “Use the same city for all widgets”) coming soon.

    Thanks for using our widget ; )

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘shortcode doesnt display city selector toggle’ is closed to new replies.