Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialOscar Mauricio Lancheros Murillo
3,608 PointsUpdate price based on foreign currency value fluctuation
Hello, I want to keep prices updated depending on dolar price.
My Store would have prices on COP, but that prices can change depending on USD price.
I want to be able to update some items prices by just adding the new price of dolar. For example, 1 USD = 2556 COP
6 Answers
Kevin Korte
28,149 PointsWould you be updating the price manually, or would it be done automatically through some API?
Oscar Mauricio Lancheros Murillo
3,608 PointsWe can start by updating it manually.
Kevin Korte
28,149 PointsOkay, and you're using wordpress?
Oscar Mauricio Lancheros Murillo
3,608 PointsYes I am using Wordpress + Woocommerce.
Kevin Korte
28,149 PointsSo on the backend you want to enter the price as USD and have it displayed as COP on the user side? You could do just simple math with PHP in your template view right before you put the price out?
Oscar Mauricio Lancheros Murillo
3,608 PointsI would like to have a single input for dolar cost and spread it to pre-ordered items to have those prices updated on COP currency.