make themes configurable (fixes #50)
* gallery.ini: - remove theme specific configuration - add default theme name * includes/galleryfunctions.php: - implement theme initialization - configure common parameters from theme * includes/theme.class.php: - implement a simple theme class * index.php: - assign $gallery to template * themes/default_horizontal/theme.ini: - add theme specific configuration * themes/default_horizontal/theme.php: - use $content['gallery'] instead of undefined $gallery
This commit is contained in:
parent
0ed421b1ce
commit
fcea03a800
6 changed files with 83 additions and 6 deletions
4
themes/default_horizontal/theme.ini
Normal file
4
themes/default_horizontal/theme.ini
Normal file
|
@ -0,0 +1,4 @@
|
|||
themename=Horizontal default theme
|
||||
themetype=horizontal
|
||||
previewsize=311
|
||||
thumbsize=67
|
|
@ -22,7 +22,7 @@
|
|||
<ul id="menu"><?php
|
||||
foreach ($content['gallerylinks'] as $data) {
|
||||
printf('<li class="menu%s"><a class="menu" href="%s">%s </a></li>',
|
||||
($data['gallery'] == $gallery) ? ' active' : '',
|
||||
($data['gallery'] == $content['gallery']) ? ' active' : '',
|
||||
$data['url'], $data['label']);
|
||||
} ?></ul>
|
||||
<div id="content_container">
|
||||
|
|
Reference in a new issue