Page 1 of 2 12 LastLast
Results 1 to 10 of 13
  1. #1
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Product Listing Sort Error (sort by price ... doesn't)

    I've just noticed an error on my site when I sort product listings (i.e. sort by price).

    When clicking on the 'Price' column header the product listing data is sorted, but it's not correct. The listing appears to be random with products not display as price ascending/descending.

    You can visit my website (adult toys retailer) by clicking on the Link in my signature.

    Has anyone else experienced a similar issue?

  2. #2
    Join Date
    Jun 2003
    Posts
    33,721
    Plugin Contributions
    0

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Check you Admin> Tools> Store Manager and run the Update ALL Products Price Sorter -
    Please do not PM for support issues: a private solution doesn't benefit the community.

    Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

  3. #3
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Hi Kim,

    Thanks for the advice... it worked great.

    Is there any reason why my price sort order went 'out of sync'?

    Also, I've noticed that the advanced search feature doesn't correctly filter out prices. For example, if I search for all items between £0.00 and £4.99 I'm displayed all the items below £5.00, but also one or two above £5.00 (i.e. £5.50).

    Could these two issues be related?

    Thanks again for the help. :)

  4. #4
    Join Date
    Jan 2004
    Posts
    66,444
    Plugin Contributions
    279

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Quote Originally Posted by Alex Clarke View Post
    I've noticed that the advanced search feature doesn't correctly filter out prices. For example, if I search for all items between £0.00 and £4.99 I'm displayed all the items below £5.00, but also one or two above £5.00 (i.e. £5.50).
    Is this related to having tax-included-in-prices by any chance?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Hi DrByte,

    You're correct. It was related to having tax-included-in-prices.

    I set Display Prices with Tax to false in my admin and the correct products were then displayed.

    I would still like to show my products inclusive of tax and also have the advanced search function take into account the tax on each product.

    Is there a way to work around this?

  6. #6
    Join Date
    Jan 2004
    Posts
    66,444
    Plugin Contributions
    279

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Quote Originally Posted by Alex Clarke View Post
    Is there a way to work around this?
    Naturally.
    Just rewrite the tax calculation logic
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  7. #7
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    No nice admin switches!?!?!

    Would I be correct in thinking that rewritting this code would be a big job?

    Also, going back to my original post, do you know why my price sort order went 'out of sync'?

  8. #8
    Join Date
    Jan 2004
    Posts
    66,444
    Plugin Contributions
    279

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Quote Originally Posted by Alex Clarke View Post
    Would I be correct in thinking that rewritting this code would be a big job?
    Yes, it's quite involved.
    Quote Originally Posted by Alex Clarke View Post
    Also, going back to my original post, do you know why my price sort order went 'out of sync'?
    That usually happens when you use external means to update database content, such as importing or manipulating product data. When you do that, the automated calculations that update the pricing details don't fire, leaving you with unexpected results.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  9. #9
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Quote Originally Posted by DrByte View Post
    That usually happens when you use external means to update database content, such as importing or manipulating product data. When you do that, the automated calculations that update the pricing details don't fire, leaving you with unexpected results.
    That makes sense, as I have a couple of scripts that update my product information (prices, special price, etc).

    Now, please correct me if I am wrong, but it should be ok to setup an automated task on my server to access the following URL admin/store_manager.php?action=update_all_products_price_sorter, which would correct the price sort order.

  10. #10
    Join Date
    Jan 2004
    Posts
    66,444
    Plugin Contributions
    279

    Default Re: Product Listing Sort Error (sort by price ... doesn't)

    Or, whenever you do an update via one of your scripts, simply call zen_update_products_price_sorter($products_id) after you apply your update. Repeat for each product you're updating.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v151 Product Sort within Category - having problems changing the default sort order
    By Don Wagner in forum Customization from the Admin
    Replies: 4
    Last Post: 21 Oct 2012, 03:03 AM
  2. [Done v139] Sale Maker listing sort by price
    By damiantaylor in forum Bug Reports
    Replies: 15
    Last Post: 31 Mar 2010, 07:42 PM
  3. Replies: 7
    Last Post: 23 Jul 2009, 06:53 AM
  4. Product sort order doesn't work- products display randomly!
    By ajshim in forum Setting Up Categories, Products, Attributes
    Replies: 9
    Last Post: 4 Dec 2007, 03:16 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg