Propagate $_ENV['staticpage_...'] so that it can be used in entries.tpl
This commit is contained in:
parent
a7fe06a369
commit
0cdfdaa13c
|
@ -1,6 +1,7 @@
|
|||
***************************************************************************************************
|
||||
* Legend: ! Bugfix, + New Features, * Changed, - Info Only
|
||||
*
|
||||
* Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
*
|
||||
* v. 1.66 2011-02-23 Spartacus
|
||||
* ===========================
|
||||
|
|
|
@ -76,7 +76,7 @@ class serendipity_event_cal extends serendipity_event {
|
|||
)
|
||||
);
|
||||
$propbag->add('author', 'Ian (Timbalu)');
|
||||
$propbag->add('version', '1.68');
|
||||
$propbag->add('version', '1.69');
|
||||
$propbag->add('groups', array('FRONTEND_FEATURES', 'BACKEND_FEATURES'));
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '1.4',
|
||||
|
@ -2198,7 +2198,9 @@ class serendipity_event_cal extends serendipity_event {
|
|||
|
||||
/* templates detection that this is not a regular entry view and avoid processing entries.tpl,
|
||||
which will obviously contain serendipity_Entry_Date, etc. */
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_', $this->get_config('pagetitle')));
|
||||
$pt = preg_replace('@[^a-z0-9]@i', '_', $this->get_config('pagetitle'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $pt);
|
||||
$_ENV['staticpage_pagetitle'] = $pt;
|
||||
|
||||
if ($this->get_config('articleformat') == true) {
|
||||
$serendipity['smarty']->assign('is_eventcal_articleformat', true);
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
latest: Smarty3 forward compatibility
|
||||
|
||||
1.11:
|
||||
|
|
|
@ -94,7 +94,7 @@ class serendipity_event_customarchive extends serendipity_event {
|
|||
$propbag->add('event_hooks', array('entries_header' => true, 'entry_display' => true, 'genpage' => true));
|
||||
$propbag->add('configuration', array('permalink', 'pagetitle', 'articleformat'));
|
||||
$propbag->add('author', 'Garvin Hicking');
|
||||
$propbag->add('version', '1.11');
|
||||
$propbag->add('version', '1.12');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.8',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -259,7 +259,9 @@ class serendipity_event_customarchive extends serendipity_event {
|
|||
if (!is_object($serendipity['smarty'])) {
|
||||
serendipity_smarty_init();
|
||||
}
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')));
|
||||
$pt = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$_ENV['staticpage_pagetitle'] = $pt;
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $pt);
|
||||
|
||||
|
||||
if ($this->get_config('articleformat') == TRUE) {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
ChangeLog:
|
||||
""""""""""
|
||||
|
||||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
latest: Smarty3 forward compatibility
|
||||
|
||||
[Version 0.26 2011/02/15] by Ian (Timbalu)
|
||||
|
|
|
@ -50,7 +50,7 @@ class serendipity_event_downloadmanager extends serendipity_event {
|
|||
'php' => '5.0.0'
|
||||
));
|
||||
|
||||
$propbag->add('version', '0.29');
|
||||
$propbag->add('version', '0.30');
|
||||
$propbag->add('author', 'Alexander \'dma147\' Mieland, Grischa Brockhaus, Ian (Timbalu)');
|
||||
$propbag->add('stackable', false);
|
||||
$propbag->add('event_hooks', array(
|
||||
|
@ -322,7 +322,8 @@ class serendipity_event_downloadmanager extends serendipity_event {
|
|||
}
|
||||
|
||||
serendipity_smarty_init();
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')));
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $_ENV['staticpage_pagetitle']);
|
||||
$this->showShoutPage();
|
||||
}
|
||||
}
|
||||
|
|
1
serendipity_event_externalphp/ChangeLog
Normal file
1
serendipity_event_externalphp/ChangeLog
Normal file
|
@ -0,0 +1 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
|
@ -23,7 +23,7 @@ class serendipity_event_externalphp extends serendipity_event {
|
|||
$propbag->add('event_hooks', array('entries_header' => true, 'entry_display' => true, 'genpage' => true));
|
||||
$propbag->add('configuration', array('permalink', 'pagetitle', 'include', 'articleformat'));
|
||||
$propbag->add('author', 'Garvin Hicking');
|
||||
$propbag->add('version', '1.3');
|
||||
$propbag->add('version', '1.4');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.7',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -91,7 +91,8 @@ class serendipity_event_externalphp extends serendipity_event {
|
|||
if (!is_object($serendipity['smarty'])) {
|
||||
serendipity_smarty_init();
|
||||
}
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')));
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $_ENV['staticpage_pagetitle']);
|
||||
|
||||
|
||||
if ($this->get_config('articleformat') == TRUE) {
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
latest: Smarty3 forward compatibility
|
||||
|
||||
0.40:
|
||||
|
|
|
@ -53,7 +53,7 @@ class serendipity_event_forum extends serendipity_event {
|
|||
'php' => '4.1.0'
|
||||
));
|
||||
|
||||
$propbag->add('version', '0.37');
|
||||
$propbag->add('version', '0.38');
|
||||
$propbag->add('author', 'Alexander \'dma147\' Mieland, http://blog.linux-stats.org, dma147@linux-stats.org');
|
||||
$propbag->add('stackable', false);
|
||||
$propbag->add('event_hooks', array(
|
||||
|
@ -356,7 +356,8 @@ class serendipity_event_forum extends serendipity_event {
|
|||
if (!is_object($serendipity['smarty'])) {
|
||||
serendipity_smarty_init();
|
||||
}
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')));
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $_ENV['staticpage_pagetitle']);
|
||||
$this->showForum();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
3.44: Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
3.43: Properly use the example() API method by returning, not echo'ing. Unimportant update.
|
||||
|
||||
3.42:
|
||||
|
|
|
@ -66,7 +66,7 @@ class serendipity_event_guestbook extends serendipity_event {
|
|||
'dateformat'
|
||||
));
|
||||
$propbag->add('author', 'Ian');
|
||||
$propbag->add('version', '3.43');
|
||||
$propbag->add('version', '3.44');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '1.3',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -1003,11 +1003,14 @@ class serendipity_event_guestbook extends serendipity_event {
|
|||
}
|
||||
|
||||
// Carl wanted the staticpage_pagetitle - see s9y-1.1 new hemingway theme index.tpl {$staticpage_pagetitle}
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$_ENV['staticpage_headline'] = $this->get_config('headline');
|
||||
$_ENV['staticpage_formorder'] = $this->get_config('formorder');
|
||||
$serendipity['smarty']->assign(
|
||||
array(
|
||||
'staticpage_headline' => $this->get_config('headline'),
|
||||
'staticpage_pagetitle' => preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')),
|
||||
'staticpage_formorder' => $this->get_config('formorder')
|
||||
'staticpage_headline' => $_ENV['staticpage_headline'],
|
||||
'staticpage_pagetitle' => $_ENV['staticpage_pagetitle'],
|
||||
'staticpage_formorder' => $_ENV['staticpage_formorder']
|
||||
)
|
||||
);
|
||||
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
4.07 Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
|
||||
4.06 Serendipity 2.0 compatibility fix for the editorbuttons (wysiwyg and default)
|
||||
|
||||
4.05 Bump version to propagate changed plugin_staticpage_related_category.tpl
|
||||
|
|
|
@ -92,7 +92,7 @@ class serendipity_event_staticpage extends serendipity_event
|
|||
$propbag->add('page_configuration', $this->config);
|
||||
$propbag->add('type_configuration', $this->config_types);
|
||||
$propbag->add('author', 'Marco Rinck, Garvin Hicking, David Rolston, Falk Doering, Stephan Manske, Pascal Uhlmann, Ian, Don Chambers');
|
||||
$propbag->add('version', '4.06');
|
||||
$propbag->add('version', '4.07');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '1.3',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -1151,7 +1151,10 @@ class serendipity_event_staticpage extends serendipity_event
|
|||
serendipity_smarty_init();
|
||||
|
||||
foreach($this->config as $staticpage_config) {
|
||||
$serendipity['smarty']->assign($pagevar . $staticpage_config, $this->get_static($staticpage_config));
|
||||
$cvar = $this->get_static($staticpage_config);
|
||||
$serendipity['smarty']->assign($pagevar . $staticpage_config, $cvar);
|
||||
// This is a global variable assignment, so that within entries.tpl you can acces $smarty.env.staticpage_pagetitle. Otherwise, $staticpage_pagetitle would only be available to index.tpl and content.tpl
|
||||
$_ENV[$pagevar . $staticpage_config] = $cvar;
|
||||
}
|
||||
|
||||
if (serendipity_db_bool($this->get_static('markup'))) {
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
latest: Smarty3 forward compatibility
|
||||
|
||||
0.10:
|
||||
|
|
|
@ -31,7 +31,7 @@ class serendipity_event_suggest extends serendipity_event {
|
|||
));
|
||||
$propbag->add('configuration', array('permalink', 'pagetitle', 'authorid', 'email'));
|
||||
$propbag->add('author', 'Garvin Hicking');
|
||||
$propbag->add('version', '0.10');
|
||||
$propbag->add('version', '0.11');
|
||||
$propbag->add('groups', array('FRONTEND_FEATURES'));
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.9',
|
||||
|
@ -224,7 +224,8 @@ class serendipity_event_suggest extends serendipity_event {
|
|||
serendipity_smarty_init();
|
||||
}
|
||||
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')));
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $_ENV['staticpage_pagetitle']);
|
||||
|
||||
$this->checkSubmit();
|
||||
|
||||
|
|
1
serendipity_event_thumbnails/ChangeLog
Normal file
1
serendipity_event_thumbnails/ChangeLog
Normal file
|
@ -0,0 +1 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
|
@ -25,7 +25,7 @@ class serendipity_event_thumbnails extends serendipity_event {
|
|||
$propbag->add('configuration', array('number'));
|
||||
$propbag->add('stackable', false);
|
||||
$propbag->add('author', 'Cameron MacFarland');
|
||||
$propbag->add('version', '1.3');
|
||||
$propbag->add('version', '1.4');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.7',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -71,6 +71,7 @@ class serendipity_event_thumbnails extends serendipity_event {
|
|||
if (!is_object($serendipity['smarty'])) {
|
||||
serendipity_smarty_init();
|
||||
}
|
||||
$_ENV['staticpage_pagetitle'] = 'thumbs';
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', 'thumbs');
|
||||
$this->generate_content($title);
|
||||
}
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
|
||||
2.55:
|
||||
-----
|
||||
Template and translation improvements
|
||||
|
|
|
@ -24,7 +24,7 @@ class serendipity_event_usergallery extends serendipity_event
|
|||
$propbag->add('description', PLUGIN_EVENT_USERGALLERY_DESC);
|
||||
$propbag->add('stackable', true);
|
||||
$propbag->add('author', 'Arnan de Gans, Matthew Groeninger, and Stefan Willoughby');
|
||||
$propbag->add('version', '2.56');
|
||||
$propbag->add('version', '2.57');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.8',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -488,7 +488,8 @@ class serendipity_event_usergallery extends serendipity_event
|
|||
return;
|
||||
}
|
||||
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('base_directory')));
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('base_directory'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $_ENV['staticpage_pagetitle']);
|
||||
$serendipity['smarty']->assign('const', array('filesize' => PLUGIN_EVENT_USERGALLERY_FILESIZE,
|
||||
'filename' => PLUGIN_EVENT_USERGALLERY_FILENAME,
|
||||
'dimension' => PLUGIN_EVENT_USERGALLERY_DIMENSION,
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
latest: Smarty3 forward compatibility
|
||||
|
||||
0.26:
|
||||
|
|
|
@ -96,7 +96,7 @@ class serendipity_event_userprofiles extends serendipity_event {
|
|||
'genpage' => true
|
||||
));
|
||||
$propbag->add('author', 'Garvin Hicking, Falk Doering');
|
||||
$propbag->add('version', '0.27');
|
||||
$propbag->add('version', '0.28');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.8',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -291,7 +291,7 @@ class serendipity_event_userprofiles extends serendipity_event {
|
|||
if ('USERLEVEL_' == substr($group['name'], 0, 10)) {
|
||||
$group['name'] = constant($group['name']);
|
||||
}
|
||||
|
||||
$_ENV['staticpage_pagetitle'] = 'userprofiles';
|
||||
$serendipity['smarty']->assign(array(
|
||||
'staticpage_pagetitle' => 'userprofiles',
|
||||
'userprofile_groups' => serendipity_getAllGroups(),
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
ChangeLog: serendipity_event_wrapurl Plugin
|
||||
""""""""""
|
||||
|
||||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
||||
|
||||
[Version 0.9 2011/08/13] by Ian (Timbalu)
|
||||
|
||||
- changed css output to support newline breaks in serendipity.css (more a cosmetic change)
|
||||
|
|
|
@ -27,7 +27,7 @@ class serendipity_event_wrapURL extends serendipity_event {
|
|||
$propbag->add('event_hooks', array('entries_header' => true, 'entry_display' => true, 'genpage' => true, 'frontend_generate_plugins' => true, 'css' => true));
|
||||
$propbag->add('configuration', array('headline', 'permalink', 'pagetitle', 'wrapurl', 'height', 'wrapurl_append', 'hide_sidebar'));
|
||||
$propbag->add('author', 'Rob Antonishen, Ian (Timbalu)');
|
||||
$propbag->add('version', '0.9');
|
||||
$propbag->add('version', '0.10');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.7',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -130,7 +130,8 @@ class serendipity_event_wrapURL extends serendipity_event {
|
|||
}
|
||||
}
|
||||
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')));
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $_ENV['staticpage_pagetitle']);
|
||||
echo '<h4 class="serendipity_title"><a href="#">' . $this->get_config('headline') . '</a></h4>';
|
||||
|
||||
echo '<div id="plugin_wrapurl_'.$serendipity['wrapurl']['id_name'].'">';
|
||||
|
|
1
serendipity_plugin_pollbox/ChangeLog
Normal file
1
serendipity_plugin_pollbox/ChangeLog
Normal file
|
@ -0,0 +1 @@
|
|||
Propagate $smarty.env.staticpage_pagetitle (and the others) so that it can be used in entries.tpl
|
|
@ -20,7 +20,7 @@ class serendipity_event_pollbox extends serendipity_event {
|
|||
$propbag->add('configuration', array('permalink', "articleformat", "pagetitle", "articleformattitle"));
|
||||
$propbag->add('author', 'Garvin Hicking');
|
||||
$propbag->add('groups', array('STATISTICS'));
|
||||
$propbag->add('version', '2.12');
|
||||
$propbag->add('version', '2.13');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.8',
|
||||
'smarty' => '2.6.7',
|
||||
|
@ -117,7 +117,8 @@ class serendipity_event_pollbox extends serendipity_event {
|
|||
if (!is_object($serendipity['smarty'])) {
|
||||
serendipity_smarty_init();
|
||||
}
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle')));
|
||||
$_ENV['staticpage_pagetitle'] = preg_replace('@[^a-z0-9]@i', '_',$this->get_config('pagetitle'));
|
||||
$serendipity['smarty']->assign('staticpage_pagetitle', $_ENV['staticpage_pagetitle']);
|
||||
|
||||
echo '<div class="serendipity_poll">';
|
||||
if (serendipity_db_bool($this->get_config('articleformat'))) {
|
||||
|
|
Loading…
Reference in a new issue