* There can only be one hook for each shortcode. Which means that if another
* plugin has a similar shortcode, it will override yours or yours will override
* theirs depending on which order the plugins are included and/or ran.
- *
+ *
* Simplest example of a shortcode tag using the API:
*
* <code>
if ( isset($m[4]) ) {
// enclosing tag - extra parameter
- return call_user_func($shortcode_tags[$tag], $attr, $m[4]);
+ return call_user_func($shortcode_tags[$tag], $attr, $m[4], $tag);
} else {
// self-closing tag
- return call_user_func($shortcode_tags[$tag], $attr);
+ return call_user_func($shortcode_tags[$tag], $attr, NULL, $tag);
}
}
*
* @since 2.5
*
- * @param string $text
+ * @param string $text
* @return array List of attributes and their value.
*/
function shortcode_parse_atts($text) {
return preg_replace('/'.$pattern.'/s', '', $content);
}
-add_filter('the_content', 'do_shortcode', 11); // AFTER wpautop()
+add_filter('the_content', 'do_shortcode', 11); // AFTER wpautop()
?>
\ No newline at end of file