mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-06-02 04:15:05 +02:00
Resolved 0000728: Add description triggers for categories and elements
Add: o render_category_description o render_category_literal_description o render_element_description git-svn-id: http://piwigo.org/svn/branches/branch-1_7@2078 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
+6
-1
@@ -55,6 +55,9 @@ add_event_handler(
|
||||
EVENT_HANDLER_PRIORITY_NEUTRAL,
|
||||
2
|
||||
);
|
||||
// add default event handler for rendering element description
|
||||
add_event_handler('render_element_description', 'nl2br');
|
||||
|
||||
trigger_action('loc_begin_picture');
|
||||
|
||||
// this is the default handler that generates the display for the element
|
||||
@@ -638,7 +641,9 @@ if (isset($picture['current']['comment'])
|
||||
$template->assign_block_vars(
|
||||
'legend',
|
||||
array(
|
||||
'COMMENT_IMG' => nl2br($picture['current']['comment'])
|
||||
'COMMENT_IMG' =>
|
||||
trigger_event('render_element_description',
|
||||
$picture['current']['comment'])
|
||||
));
|
||||
$header_infos['COMMENT'] = strip_tags($picture['current']['comment']);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user