Global variables documentation |


I am getting along very nicely with this plugin. I’m now interested in playing around with the global variables, in an attempt to make a currency switcher button for the website.

How do the global variables work if I would like to convert all prices on a page? Do I have provide the logic, or is that provided by the plugin? I can’t determine from the description:

The variables are global_convert_from and global_convert_to.

This is useful if, say, you have multiple versions of the site in different languages – you can then assign these global variables depending on which site is being viewed and all currency will be converted based upon these settings.

These will only override the options screen and not specific parameters specified with a shortcode or function call.

Does this mean the global variables ONLY define a default from / to currency, in case from /to is omitted in a conversion operation?

I am writing all code in php, so trying to understand in which scenario I should use the global variables and what difference they make.

  • This topic was modified 7 hours, 19 minutes ago by kalle.
  • This topic was modified 7 hours, 17 minutes ago by kalle.


This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer