WP Ultimo offers some handy shortcodes to be used on your network’s front-end. Here is a list containing all of them and how to use them.
Since version 1.5.0 admins can use the Restrict Content shortcode to add content to the main site directed to subscribers only. It takes the following form:
[wu_restricted_content plan_id="all" only_active=0]
Default content displayed to non-subscribers
The plan_id argument takes a list of plan ids separated by commas, or the word all to allow every plan.
The only_active argument, if set to 0, only displays the restricted content to active subscription. If that attribute is omitted, all the content will be displayed to all users with subscriptions, active or not.
You can also use the only_logged argument, to decide if the restriction should be applied based on the current site subscription status. If set to 1, it will use the current user’s account to determine if the content should be displayed or not.
To display our pricing tables you can use the shortcode [wu_pricing_table]. That will include the pricing tables with the select button for each plan. Clicking on the select button will then start the sign-up process, skipping the plan selection step.
This handy shortcode [wu_templates_list] can be used to display the Template List on the front-end of your site. You can also hide the filter using the argument show_filters=”0″.
If you need to generate a URL that starts the sign-up process directly from a specific plan and frequency, you should use the shortcode [wu_plan_link]. It takes two arguments, plan_id and plan_freq. Use the plan id on the URL of the edit page of the plan you want to generate the URL. For the plan_freq, you can use 1 for monthly, 3 for quarterly, and 12 for yearly billing. The final shortcode will look something like [wu_plan_link plan_id=”70″ plan_freq=”1″].
[wu_paying_users] is a simple shortcode that just displays the number of paying users on your network. Useful for adding some statistics on your home page to help convert potential subscribers!
WP Ultimo also exposes a shortcode to display user meta information on the front-end: [wu_user_meta]. It takes a user_id argument (which you can leave blank as it defaults to the current site’s owner id) and meta_name, which describes the name of the meta info you want to retrieve. To get the user’s last name, for example, you would simply add a [wu_user_meta meta_name=”last_name”]. This is how you would display some info gathered during a sign-up flow with custom fields.