Jump to content
Sign in to follow this  
petsk

"Enhanced New Products Module.." contribution

Recommended Posts

Hi everyone :rolleyes:

 

I installed the 'Enhanced New Products Module' contribution on my MS2 store.

The contribution adds two links beneath each product image in "New Products for month"-module, a "Read more" and "Buy now" link.

I also use the contribution 'Non Online Purchase' wish lets you hide the ?Add to Cart? button by changing a setting in the admin area.

 

The problem is?

When I set a product as ?not for online purchase? in the admin, the ?Enhanced New Products Module? still shows the ?Read more? and ?Buy now?-links on each product in the module "New Products for month".

That means that costumers still are able to buy products that actually aren?t for online purchase.

 

:-"

I have figured out that this code below here needs to check if the product is purchase able or non-purchase able by checking the database table manufactures for the flag that tells if the product is for online purchase or not, or am I totally wrong!?

 

Line 34 in file catalog/includes/new_products.php whit ?Enhanced New Products Module? installed:

'text' => '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $new_products['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $new_products['products_image'], $new_products['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a><br><a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $new_products['products_id']) . '">' . $new_products['products_name'] . '</a><br>' . $currencies->display_price($new_products['products_price'], tep_get_tax_rate($new_products['products_tax_class_id'])));

 

And this is the sql query that I have inserted to the database, that tells if the product is purchase able or not:

alter table manufacturers add disable_addtobasket enum('Y','N') DEFAULT 'N' after manufacturers_image;

 

 

I don?t have any PHP skills so I don?t know how to get this working properly, but I hope that a kind person can help me a little here :blush:

 

 

Peter

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×