This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This thread is resolved. Here is a description of the problem and solution.

Problem: I want to know how to move the currency switcher to where the product price is. or at least want to know which file i need to modify in order to achieve that.

Solution: The template that you need to overwrite are called simple.php (locared in wp-content/woocommerce/templates/single-product/add-to-cart folder) and price.php (located in wp-content/woocommerce/templates/single-product).

Basically, all you have to do is copy these two templates in your child theme, and copy the add to cart element to the price template.

This topic contains 2 replies, has 2 voices.

Last updated by pengp 1 week, 3 days ago.

Assigned support staff: Radu.

Author Posts
October 1, 2019 at 4:20 pm #4673957

pengp

Tell us what you are trying to do?
I want to know how to move the currency switcher to where the product price is. or at least want to know which file i need to modify in order to achieve that.

Is there any documentation that you are following?
none

Is there a similar example that we can see?
no

What is the link to your site?
hidden link

October 1, 2019 at 8:27 pm #4675295

Radu
Supporter

Languages: English (English )

Timezone: Europe/Bucharest (GMT+03:00)

Hey,

Thank you for reaching out the WPML support!

I understand what you'd like to do. However, that button is added there, using some templates from WooCommerce. Changing the position of that button requires some custom coding inside this template.

I can point you to the file that you need to edit but you're the one that needs to take care of the changes. The template that you need to overwrite are called simple.php (locared in wp-content/woocommerce/templates/single-product/add-to-cart folder) and price.php (located in wp-content/woocommerce/templates/single-product).

Basically, all you have to do is copy these two templates in your child theme, and copy the add to cart element to the price template. You can give this a try 🙂

Regards,
Radu

October 8, 2019 at 1:52 am #4711257

pengp

My issue is resolved now. Thank you!