Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Can I create a link from menu to "specials.php" page?


BuddahBoy

Recommended Posts

I was having a look around earlier today for some help on the specials (in my case, how to upload lots in one go like with EP) and I noticed there were a couple of contributions that add a Specials category. Have you had a look at those to see if they do what you want?

 

:)

Link to comment
Share on other sites

Thanks Deena but the one that sounded just right (specials_category) doesn't give enough info for someone like to place the code as I have modded files already. I can't go by line numbers and am not proficient enough in php to identify the correct placing - for example, here is part of the file:

 

At line 15 immediately after:

 

require('includes/application_top.php');

 

add:

 

// Flag for SPECIALS category - change this number to your specials category id number

if ($cPath == 30) { change 30 to xx from your URL

$AHspecials = 1;

}

 

+++++++++++++++++++++++++++++++

 

Step 3:

 

at about line 186 immediately after

 

{ else }

 

add:

 

 

if ($AHspecials == 1) {

// We show all specials

$listing_sql = "select " . $select_column_list . " p.products_id, pd.short_desc, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on p.manufacturers_id = m.manufacturers_id left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where s.status = '1' and p.products_id = p2c.products_id and p.products_id = s.products_id and pd.products_id = p2c.products_id and pd.language_id = '" . (int)$languages_id . "'";

} else {

 

 

+++++++++++++++++++++++++++++++++

 

Step 4:

 

at about line 199 immediately after

 

}

}

 

add:

 

}

 

+++++++++++++++++++++++++++++++++

 

I did look more and don't find something else

 

Thanks for the feedback though

Ron

Link to comment
Share on other sites

In the alternative, is there another way to do it?

 

As you've added a new category for this it will have a cPath of its own. Look at it in osC admin, do a mouseover and you'll see the Category number. You then create a link like this:

 

<a href="index.php?cPath=52">Specials"</a> and add it to somewhere like the header.php file.

 

Vger

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...