Omeka_View_Helper_Shortcodes
Package: View\Helper
- class Omeka_View_Helper_Shortcodes
extends Zend_View_Helper_Abstract
View helper for processing shortcodes in text.
- property Omeka_View_Helper_Shortcodes::$shortcodeCallbacks
protected array
List of predefined shortcodes.
- Omeka_View_Helper_Shortcodes::addShortcode($shortcodeName, $callback)
Add a new shortcode.
- Parameters:
$shortcodeName (
string
) – Name of the shortcode$callback (
callback
) – Callback function that will return the shortcode content
- Omeka_View_Helper_Shortcodes::shortcodes($content)
Process any shortcodes in the given text.
- Parameters:
$content (
string
)- Returns:
string
- Omeka_View_Helper_Shortcodes::handleShortcode($matches)
Parse a detected shortcode and replace it with its actual content.
- Parameters:
$matches (
array
)- Returns:
string
- Omeka_View_Helper_Shortcodes::parseShortcodeAttributes($text)
Parse attributes section of a shortcode.
- Parameters:
$text (
string
)- Returns:
array
- Omeka_View_Helper_Shortcodes::shortcodeRecentItems($args, $view)
Shortcode for printing recently added items.
- Parameters:
$args (
array
)$view (
Omeka_View
)- Returns:
string
- Omeka_View_Helper_Shortcodes::shortcodeFeaturedItems($args, $view)
Shortcode for printing featured items.
- Parameters:
$args (
array
)$view (
Omeka_View
)- Returns:
string
- Omeka_View_Helper_Shortcodes::shortcodeItems($args, $view)
Shortcode for printing one or more items
- Parameters:
$args (
array
)$view (
Omeka_View
)- Returns:
string
- Omeka_View_Helper_Shortcodes::shortcodeCollections($args, $view)
Shortcode for printing one or more collections
- Parameters:
$args (
array
)$view (
Omeka_View
)- Returns:
string
- Omeka_View_Helper_Shortcodes::shortcodeRecentCollections($args, $view)
Shortcode for printing recent collections
- Parameters:
$args (
array
)$view (
Omeka_View
)- Returns:
string
- Omeka_View_Helper_Shortcodes::shortcodeFeaturedCollections($args, $view)
Shortcode for printing featured collections
- Parameters:
$args (
array
)$view (
Omeka_View
)- Returns:
string
- Omeka_View_Helper_Shortcodes::shortcodeFile($args, $view)
Shortcode for displaying a single file.
- Parameters:
$args (
array
)$view (
Omeka_View
)- Returns:
string