Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Featured Products only on the default index page


jhande

Recommended Posts

Posted

I have my New for the Month box set to display recent additions to the shop, set at 30 limit.

 

I like having that feature once the customers are into the categories so they can see what's new, possibly from their last visit.

 

I was wondering though if there was a way to change just the What's New box on the opening index page to a Featured Products box without effecting the other boxes.

 

If not, does anyone recommend using a scrolling type featured infobox?

- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Posted

Yes you can. You'd need to install a featured product contribution. To remove the new products for the month box and replace it with the featured box look in your index.php file and find the last instance of:

<?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?>

 

You will be able to replace the above code with code from the installation instructions of your featured product contribution.

Posted

Am sorry, I misread the question so my other reply doesn't help you at all!

Posted

Thanks for looking and trying anyways Richard. ;)

- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Posted

In your index.php there are 2 instances of

<td><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

 

If I am not mistaken, then the first 1 is for the boxes that show up in your category pages. The 2nd is for the box that shows up in your homepage. So if you replace the 2nd instance with a featured products module, your new products will still show up on the category pages.

Posted

Thank you Ashley, I will give that a try tonight.

 

;)

- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Posted

Am a little confused...

 

Are we talking about New products for XXXXX (month) on the index.php page or are we talking about the What's New box which is either on the left or right hand side?

 

If we are talking about the New products for XXXXX then my first reply applies but if we are talking about the What's New box then you'd need a bit of code in the column_left.php or column_right.php to only show the new featured box if the customer is on the index.php page.

Posted

If you do mean the What's New infobox either on the left or the right column then when you come to add the featured box to the column_left.php or the column_right.php file you want to add the following code:

 

if ( basename($_SERVER['PHP_SELF']) == FILENAME_DEFAULT && $current_category_id == 'NULL' ){

require(DIR_WS_BOXES . 'XXXXX.php');

}else{

};

 

Replacing XXXXX.php with your box name. The above code will stop the featured box showing on any other page apart from the index.php page.

Posted
Am a little confused...

 

Are we talking about New products for XXXXX (month) on the index.php page or .....

 

I think that's what Jim wants. Your first reply was correct. I have it working on my site like that. Featured products on the homepage and new products in the category pages.

Posted

Yes Richard you were correct. After looking at your original post again it made sense.

 

And thank you Ashely for clarifying. ;)

 

 

3 days without sleep makes it kind of difficult to grasp things right away. :blink:

 

I haven't attempted the install yet, will after a good nights sleep.

 

Thanks again folks for helping, much appreciated.

- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...