Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

How to display product sort by discount

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #1  
Old 04-23-2015, 02:32 AM
 
xtech xtech is offline
 

X-Adept
  
Join Date: Jun 2010
Posts: 605
 

Default How to display product sort by discount

Hi,
How to sort by products by discounts in category page?

Thanks,
xtech
__________________
X-cart Platinum
4.6.1
Reboot template
Reply With Quote
  #2  
Old 04-24-2015, 01:11 PM
  totaltec's Avatar 
totaltec totaltec is offline
 

X-Guru
  
Join Date: Jan 2007
Location: Louisville, KY USA
Posts: 5,823
 

Default Re: How to display product sort by discount

What do you mean by discounts? Can you specify any additional criteria? Are you talking about special offers? Do you want to sort by products that have special offers, and display all products with special offers at the top?

That could be very difficult. Or are you talking about some other type of discount?
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey

XcartGuru
X-cart Tutorials | X-cart 5 Tutorials

Check out the responsive template for X-cart.
Reply With Quote
  #3  
Old 04-24-2015, 04:08 PM
 
xtech xtech is offline
 

X-Adept
  
Join Date: Jun 2010
Posts: 605
 

Default Re: How to display product sort by discount

Quote:
Originally Posted by totaltec
What do you mean by discounts? Can you specify any additional criteria? Are you talking about special offers? Do you want to sort by products that have special offers, and display all products with special offers at the top?

That could be very difficult. Or are you talking about some other type of discount?
any type of discount like difference between market price and our price.
__________________
X-cart Platinum
4.6.1
Reboot template
Reply With Quote
  #4  
Old 04-27-2015, 09:33 PM
 
xtech xtech is offline
 

X-Adept
  
Join Date: Jun 2010
Posts: 605
 

Default Re: How to display product sort by discount

Quote:
Originally Posted by totaltec
What do you mean by discounts? Can you specify any additional criteria? Are you talking about special offers? Do you want to sort by products that have special offers, and display all products with special offers at the top?

That could be very difficult. Or are you talking about some other type of discount?

Hi Mike,
How to achieve that?

Thanks a lot.

Regards,
xtech
__________________
X-cart Platinum
4.6.1
Reboot template
Reply With Quote
  #5  
Old 04-28-2015, 05:24 AM
  totaltec's Avatar 
totaltec totaltec is offline
 

X-Guru
  
Join Date: Jan 2007
Location: Louisville, KY USA
Posts: 5,823
 

Default Re: How to display product sort by discount

The majority of the code you need to edit would be in include/search.php

It is not an easy task that I can quickly describe the solution to. Plus I think we need more clarification on exactly what we want to accomplish. At first I think you should focus on one type of discount, like market price vs our price as you mentioned above.

But you need to decide exactly how you want this to work. Currently there are a number of selections to sort products by: Product (Name), Price, Default (Admin order), and Rating.

Are you wanting to add a selection there for your visitors? Another option: Discount? Or are you wanting to float discounted products to the top when sorted some other way? Or only list them at the top when Default sort is used?

There are so many unanswered questions here, it takes an interview to determine exactly what you want.

When the products are sorted by discount, does the algorithm need to determine the level of discount and order them from most discounted to least? What will be the determining factor, dollar amount or percentage? After the discounted products have been arranged, how are the rest of the items that do not have discounts ordered? Default? Price?
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey

XcartGuru
X-cart Tutorials | X-cart 5 Tutorials

Check out the responsive template for X-cart.
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 03:46 PM.

   

 
X-Cart forums © 2001-2020