1

I am building a new Magento store. 80% of the products are affiliate products, where the price needs to be displayed in it's original currency. 20% of the products are regular products in the store's base currency (e.g. €), which can be added to the shopping cart.

Example:

  • Product C 19€ ==> Add to cart / buy now.
  • Product A 10& ==> Affiliate link
  • Product B 15$ ==> Affiliate link

The 'Buy Now' button for each affiliate product will simply be an affiliate link (no need to add these products to the shopping cart).

I want different products to display their prices in different currencies (one price per product).

Questions:

  1. With vanilla megento, is it possible to have different currency symbol displayed for each product?

  2. I plan to implement affiliate products by creating a custom product type using this code. Will it help?

  3. Any other option?

Please advise

Also, is there a calculator which allows the user to convert the price to their local currency? (to get an estimation).

2

Since it has no impact on your price calculation, the simplest solution is to add a product attribute, for example "Affiliate Currency". Then you probably have to rewrite price.phtml. The formatPrice() function is tied deep into the store model and I don't see an easy way to rewrite that, since you have no product information available, meaning you'd need a different method signature.

I'd probably make a wrapper formatPriceForProduct(), where you can pass the product model and offload to the default formatPrice if no Affiliate Currency is set and do your own formatting if it is.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.