Step 1: Install and Activate the Shortcode Engine
- Download the package to your harddrive from the link provided. It will be called shortcodes_UNZIP1st.zip
- Unzip the package
- Using the Extension Manager with J! 1.5 or 2.5, install plg_shortcodes.zip
- From the Plugin Manager, select and activate the System - Shortcode plugin
Note: You can choose to run the plugin on Content only, or on the entire page. The entire page handles shortcodes running in module positions and on templates, and is faster. Content only (the default) is safter and runs only on articles and (in 2.5) optionally modules.
- The engine is now installed
Step 2: Installing individual Shortcode Plugins
In keeping with the philosophy of Joomla!, you can install shortcodes packs as individual plugins. To install a shortcode, install the zip file using the Joomla! extension manager then activate it from the plugin manager.
Each package may contain one or more individual shortcodes. How to use it is presented in the shortcode plugin manager.
Wordpress users are usually instructed to add new shortcodes to the functions.php file in their theme. Joomla! does not work this way. Instead, we've included a package called shortcode default with a simple [test] shortcode included. You should install that package, activate it, then add any extra shortcodes you want to the plugins/shortcode/shortcode_default.php file.
Troubleshooting: When installing a shortcode for the first time, the system must make a new folder called "plugins/shortcode". If the system can't create this folder, the installation will fail. If this happens to you, then make sure the "plugins" directory is writeable, then retry the installation.
For additional help, please contact support.
Included Shortcode Plugins
[test] shortcode to make sure everything is working. Also provides shortcode_default.php file so you can add your other, non joomla packaged shortcodes you may find on the internet.
Joomla Youtube Shortcode [youtube]
This shortcode embeds a Youtube video without the need of additional plugins or components.
Example: [youtube src='http://www.youtube.com/watch?v=oHg5SJYRHA0']
The only required paramater is “video”.
This shortcode obfuscates any email address so bots can’t scrape them.
The Tweet Shortcode provides a tweetmeme button anywhere it appears.
use like: [tweet]
Embed a PDF in your website.
Example: [embedpdf width="600px" height="500px"]http://infolab.stanford.edu/pub/papers/google.pdf[/embedpdf]
This plugin allows you to add a snapshot of a web page to your website.
Example: [snapshot url="http://www.nicktemple.com" alt="My Favorite Website" w="400" h="300"]
The user shortcode displays content based on information about the current user.
You can use this to show the users their name, for example “Hi! Name”, username, or registered date.
You can also provide content based on whether the user is registered and logged in or not. This is perfect
for providing teaser text for membership sites.
Example: Print the uses name, or “Anonymous” if it isn’t available:
[user echo="name" default="Anonymous"]
[user echo="username" default="Unregistered"]
Example: To display content:
[usercontent loggedin="true" default="Please reigster!"]
This text is displayed only to LOGGED IN users!
The words “Please Reigister” are displayed to users who are not logged in.
This text is displayed only to Anonymous (not logged in visitors).
Users who are logged in see nothing.