Update of /cvsroot/php-blog/serendipity/plugins/serendipity_event_templatechooser
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15613/plugins/serendipity_event_templatechooser
Modified Files:
Tag: branch-smarty
serendipity_event_templatechooser.php
Log Message:
- New plugin manager
- Give some of the plugin longer descriptions
- Allow plugins to set 'stackable' directive to false which will prevent it from being installed more than once - Still 'beta'
- MFH plugin config redirection fix
Index: serendipity_event_templatechooser.php
===================================================================
RCS file: /cvsroot/php-blog/serendipity/plugins/serendipity_event_templatechooser/serendipity_event_templatechooser.php,v
retrieving revision 1.3
retrieving revision 1.3.2.1
diff -u -d -r1.3 -r1.3.2.1
--- serendipity_event_templatechooser.php 26 Apr 2004 11:01:51 -0000 1.3
+++ serendipity_event_templatechooser.php 28 Oct 2004 20:17:32 -0000 1.3.2.1
@@ -9,7 +9,7 @@
case 'en':
default:
@define('PLUGIN_EVENT_TEMPLATECHOOSER_NAME', 'Template chooser');
- @define('PLUGIN_EVENT_TEMPLATECHOOSER_DESC', 'Allows users to change the template');
+ @define('PLUGIN_EVENT_TEMPLATECHOOSER_DESC', 'Allows your visitors to change template on the fly');
break;
}
@@ -18,7 +18,7 @@
function introspect(&$propbag)
{
global $serendipity;
-
+
$propbag->add('name', PLUGIN_EVENT_TEMPLATECHOOSER_NAME);
$propbag->add('description', PLUGIN_EVENT_TEMPLATECHOOSER_DESC);
$propbag->add('event_hooks', array('frontend_configure' => true));
@@ -26,16 +26,16 @@
// Register (multiple) dependencies. KEY is the name of the depending plugin. VALUE is a mode of either 'remove' or 'keep'.
// If the mode 'remove' is set, removing the plugin results in a removal of the depending plugin. 'Keep' meens to
// not touch the depending plugin.
- $this->dependencies = array('serendipity_plugin_templatedropdown' => 'remove');
+ $this->dependencies = array('serendipity_plugin_templatedropdown' => 'remove');
}
-
+
function generate_content(&$title) {
$title = PLUGIN_EVENT_TEMPLATECHOOSER_NAME;
}
function event_hook($event, &$bag, &$eventData) {
global $serendipity;
-
+
$hooks = &$bag->get('event_hooks');
if (isset($hooks[$event])) {
@@ -49,7 +49,7 @@
if (isset($_SESSION['serendipityUseTemplate']) ) {
$eventData['template'] = $_SESSION['serendipityUseTemplate'];
}
-
+
return true;
break;
|