This plugin hasn’t been tested with the latest 3 major releases of WordPress. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.

Mindvalley Post & Get Variables

Description

Outputs $_POST or $_GET variable values using shortcodes.

Super duper uberly useful on tracking scripts on eCommerce thank you pages.

Example:

  • $_POST[’emailโ€™] > [post_var name=โ€emailโ€]
  • $_GET[โ€˜txn_idโ€™] > [get_var name=โ€txn_idโ€]

For Array values :

  • $_POST[โ€˜userโ€™][’emailโ€™] > [post_var] name=โ€user[email]โ€ [/post_var]
  • $_GET[โ€˜userโ€™][โ€˜first_nameโ€™] > [get_var] name=โ€user[first_name]โ€ [/get_var]
  • $_GET[โ€˜userโ€™][โ€˜addressโ€™][โ€˜line1โ€™] > [get_var] name=โ€user[address][line1]โ€ [/get_var]

Note: Remember to wrap the name attribute in double quotes (โ€œ).

Installation

  1. Upload plugin folder to the /wp-content/plugins/ directory
  2. Activate the plugin through the โ€˜Pluginsโ€™ menu in WordPress
  3. Enjoy!

FAQ

Why I can’t get some of the URL variables?

WordPress has a set of reserved GET variables that is used for page querying. For example, โ€˜nameโ€™ or โ€˜page_idโ€™ or โ€˜idโ€™ can’t be used without having some unexpected results.

Array variables are not showing up.

Verify that you wrap your the variable settings within a double quote (โ€œ), or else it won’t work.

Reviews

There are no reviews for this plugin.

Contributors & Developers

“Mindvalley Post & Get Variables” is open source software. The following people have contributed to this plugin.

Contributors

Changelog

1.0

Initial Release.

1.0.2

Add support for array $_POST / $_GET variables

1.0.3

Additional checks to avoid unnecessary PHP warnings if the key provided appears to be an array.

1.0.4

Bug fix.

1.0.6

Support PHP auto replacements POST / GET variables with underscores