Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
  • #21678

    Hello Dear support team! have a new topic =))

    It’s very useful button – product order on the top of shop, but it not useful to have it there, in individual place, far from main widgets… How can i put it on widget sidebar?

    Thanks a lot for your advice!!!


    I did not test it but you can try to add following code into a text widget:

    <form class="woocommerce-ordering" method="get">
    <select name="orderby" class="orderby">
    <option value="menu_order" >Default sorting</option><option value="popularity" selected='selected'>Sort by popularity</option><option value="rating" >Sort by average rating</option><option value="date" >Sort by newness</option><option value="price" >Sort by price: low to high</option><option value="price-desc" >Sort by price: high to low</option> </select>
    <input type="hidden" name="attest" value="true" /></form>

    Probably it will work just fine.


    Dude! It works!

    Thanks a lot!

    But it’s only one bug. Check how this widget working now. Default ordering is set to popularity, but when i’m choosing other kind of ordering, i can’t make popularity again… Have you some suggestions?

    Thanks a lot!


    And Extra question – where i can change localization for this widget? It’s not in woocommerce localization file…

    And again – address of page (widget area is on the right side)


    Hi rudolfkrajewski,

    The translation would have to be done within the code that Dude provided (ie its not set to be translatable as part of a po file or anything because its just a text widget).

    When I look at it, popularity is always an option.




    Devin! It’s really works with localization in code!

    But still works strange with selection of ordering type. Just try to select any kind of ordering and then use popularity (за популярністю) again, and you can’t use it. it’s will stay same kind of ordering.

    And again – address of page (widget area is on the right side)

    And THANKS a lot!

    Support Dream Team! =)


    I’m not sure if its working correctly or not actually. I know it is supposed to be popularity, I just don’t know what that is calculated under. Right now its using popularity the same as Rating which sounds like it may be correct unless woocommerce has an actual way of determining popularity outside of a rating.




    Dear Devin! Thanks a lot for respond.

    Let me explain problem exactly:

    filter now is set to popularity as default, but if you choose other kind of ordering, you’ll never get a chance to change it back to popularity untill you’ll reload a page. Just try. за популярністю – is popularity.

    And again, thanks a lot for not leave me with this question!!!




    I am getting an error on your page coming from google translate

    XMLHttpRequest cannot load Origin is not allowed by Access-Control-Allow-Origin.

    Here it says how to fix that.

    But you got other issues. Please check the code on your website since you have either a single or a double quote missing somewhere, and i think this is causing some javascript file to not load causing the problem with sorting.

    Take a look – > bad formatting ..




    Dear Nick

    Thanks a lot for advice! I’ll try to figure it out a will let you know the result!



    Ok. Please let us know.



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

The topic ‘WOOCOMMERCE DEFAULT SORTING BUTTON/SELECTOR – need to put it on widget column’ is closed to new replies.