Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

One "required" product when buy products from 1 specific category, possible?


Recommended Posts

Dear all,

I am looking for days, and weeks for a solution for the next thing: (i checked the addon directory but could not find anything what looks like this).

I have a categorie (X) with "danger" products. If the customer wants to buy one or more products from THIS (X) category, OSC must add automaticly safety glasses (€2,00) to the shopping cart for protecting the eyes.

It's neccesairy that the customer can NOT delete the safety glasses product from shopping cart when there are still danger products in shopping cart from that category X. The only possibility to delete the glasses is when the customer delete the product/products from danger category X out of the shopping cart.
Is this possible in, maybe, a realitive simple way? 

For example:

Customer buys 1 product from category A (No danger goods) -> nothing happens
Than customer buys 1 product from category X (danger goods) -> safety glasses automaticly added in shopping cart
If the customer buys more danger goods, the safety glasses have to stay at one piece. Not changeable to other amounts. Max and minimal 1 piece of glasses!

Hope someone can help me, i am not a professional in scripting, so now it's very difficult!

I still use OSC V2.2

Edited by madmike1
Link to comment
Share on other sites

Not sure if what you are asking is strictly legal! No one should be forced to by something they don’t need. How do you know they don’t already have safety equipment?

If its that important then simply add the item to each danger product and sell them as a bundle.


You could look at one of the many cross sell add-ons to see if you can get that to work as you need.






If not post in the commercial section to see if one of the developers can help.



Link to comment
Share on other sites

If I already owned a collection of quality safety glasses or goggles, I would be quite annoyed if you forced me to buy yet another pair. Is this some EU law, rather than just letting you add "HAZARD! Use only with good safety glasses (such as this pair you can buy here)."? If they're cheap glasses, consider just throwing them in as a gift. Or is this just an example you thought of off the top of your head? If it's essential that the customer buy "B" to go along with "A", and "B" is cheap enough, it might be easier to just throw "B" in with "A".  If "B" was expensive enough, that could be a problem (the customer would want to buy only one).

I still use OSC V2.2

Ack! Please strongly consider upgrading to the current version, Edge/CE/Frozen. You're making so much extra work for yourself, and some day your site will crash badly when your host upgrades something.

Link to comment
Share on other sites

Although there are bundled products addons available you may be better off using a cross sell addon, or something that allows a customer to buy two items together at a discount price. Something like the better together addon, but it may require some code changes to bring it up to date. May be do a starter bundle that includes all the safety gear that is needed for a particular product.

Forcing someone to buy something that they may already have will loose you customers, but its up to you what you try to increase sales.


Link to comment
Share on other sites

Actually if you are able to get over forcing someone to buy then the product attributes will do everything you need.


Simply add the safety gear as an option on each danger product. Then the customer is free to buy with or with out.


Link to comment
Share on other sites

The other option, if you are required to do this for some reason, is just to include it and build the cost into the goods.


Link to comment
Share on other sites

6 hours ago, madmike1 said:

This one looks good! How to buy this one, i cant found anything about contact with the maker on the page. 

Your osCommerce version is too old.  That was just for further reading so you can see it can be done (and easily; "upload, turn on module, set parameters, forget") in modern (ie within last 5 years) versions of osCommerce.


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...