Integrate the new web content optimization API from Myna and let your best content automatically display according to real user data. With this plugin, you can manage all of your interactions with Myna from within the Admin area of WordPress (including viewing data), saving you time: create and manage experiments and variables, integrate content suggestions through shortcodes or template functions, and automatically return the value to Myna.
Why Use Myna?
- Simple — you don’t need to make any decisions about experimental parameters before you begin, and you don’t need to know any stats to interpret the results.
- Flexible — you can add and remove page variations at any time.
Adaptable — Myna reacts to changes in customer preferences automatically. You don’t have to lift a finger.
- Fast — Myna optimizes your page right from the start. There’s no need to wait for experiments to finish before making a decision.
This plugin is on GitHub, so feel free to contribute, request a feature, or fork it for your own purposes.
- Myna Account
- PHP 5
- Upload the
myna-for-wpfolder to the
- Activate the plugin through the ‘Plugins’ menu in WordPress.
- Add login information to the settings page (Settings > Myna).
- Add experiments and variables on the settings page as needed.
- Use the shortcode in your posts and pages, use the
myna_linkfunction in your template file, or use the more advanced
The shortcode allows you to place a dynamic Myna link in a post (of any type) or page. The options are:
[myna uuid="string" link="string" newwin=boolean]Link Text[/myna]
- ‘uuid’ is your Myna Experiment UUID.
- ‘link’ is where your created link will point (href).
- ‘newwin’ is a true/false that will make the link open in a new window (target=”_blank”).
So, for intance:
[myna uuid="72a3dd4f-73f2-4a18-a99f-a14a6b3e8e0d" link="http://google.com" newwin=true]Testing This[/myna]
<a href="http://google.com" rel="72a3dd4f-73f2-4a18-a99f-a14a6b3e8e0d" target="_blank" class="mynaSuggest">Myna Suggestion (which replaced Testing This)</a>
Main Template Function
This is the same function as the shortcode, but designed to be used in theme/template files. Using the same guidelines as above, the options are:
The only difference is that the default text (to be replaced on load by a Myna suggestion) is the third parameter in the function. So, for instance:
<a href="http://google.com" rel="72a3dd4f-73f2-4a18-a99f-a14a6b3e8e0d" class="mynaSuggest" target="_blank">Myna Suggestion (which replaced Default Text)</a>
The default text is then replaced by the Myna suggestion when the document has loaded.
Advanced Template Function
This returns the values for use. As of this plugin version, this response has the following name/value pairs (according to http://mynaweb.com/docs/api.html#suggest):
token: String This is a unique identifier that must be sent back to the server when reward is called
choice: String The name of the variant the experiment has chosen
So, for instance:
will allow you to
echo $myna->choice and so on. Please note: this function is for advanced integration, for whatever reason you may have. It will not automatically register the success of your experiment response; you’ll need to find a way to send the token back to Myna.
Contributors & Developers
“Myna for WordPress” is open source software. The following people have contributed to this plugin.Contributors
Interested in development?
Fix experiments creation and display bug
- Performance enhancements and fallbacks for when Myna might be down
- Fixed links in Admin area
Update for new Myna JS Client: uses new CDN’d JS file, falls back to local when unavailable, and
updated suggestion/reward functionality