1 | <?php |
---|
2 | /* |
---|
3 | Theme Name: flop_mauve |
---|
4 | Version: auto |
---|
5 | Description: A mauve theme derived from the dark theme of piwigo |
---|
6 | Theme URI: http://fr.piwigo.org/ext/extension_view.php?eid=62 |
---|
7 | Author: flop25 |
---|
8 | Author URI: http://www.planete-flop.fr |
---|
9 | */ |
---|
10 | $themeconf = array( |
---|
11 | 'name' => 'flop_mauve', |
---|
12 | 'parent' => 'default', |
---|
13 | 'icon_dir' => 'themes/default/icon', |
---|
14 | 'mime_icon_dir' => 'themes/default/icon/mimetypes/', |
---|
15 | 'local_head' => 'local_head.tpl', |
---|
16 | 'colorscheme' => 'clear', |
---|
17 | ); |
---|
18 | |
---|
19 | $conf['level_separator'] = ' » '; |
---|
20 | $conf['paginate_pages_around'] = 7; |
---|
21 | $conf['show_picture_name_on_title'] = false; |
---|
22 | $conf['show_thumbnail_caption'] = false; |
---|
23 | /** mainpage_categories.tpl **/ |
---|
24 | add_event_handler('loc_end_index_category_thumbnails', 'flopmauve_cat'); |
---|
25 | function flopmauve_cat($tpl_thumbnails_var) |
---|
26 | { |
---|
27 | global $template; |
---|
28 | $template->set_prefilter('index_category_thumbnails', 'flopmauve_cat_pre'); |
---|
29 | return $tpl_thumbnails_var; |
---|
30 | } |
---|
31 | function flopmauve_cat_pre($content, &$smarty) |
---|
32 | { |
---|
33 | $search = 'NAME}</a>'; |
---|
34 | $replacement = 'NAME|truncate:38:" [...]"|strip_tags}</a>'; |
---|
35 | $content=str_replace($search, $replacement, $content); |
---|
36 | $search = 'DESCRIPTION}</p>'; |
---|
37 | $replacement = 'DESCRIPTION|truncate:120:" [...]"|strip_tags}</p>'; |
---|
38 | return str_replace($search, $replacement, $content); |
---|
39 | } |
---|
40 | |
---|
41 | ?> |
---|