Update of /cvsroot/php-blog/serendipity/plugins/serendipity_event_s9ymarkup
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20254/plugins/serendipity_event_s9ymarkup
Modified Files:
Tag: branch_0_6
serendipity_event_s9ymarkup.php
Log Message:
MFH:
* Upgrader kills the current session for possible changes inside session
data on upgrade
* Fixed wrong comparison operator - bug reported by tom, where nl2br plugin
has "reversed" logic.
This is because (true != 'false') evaluates to true. Plugin config did not
evaluate radio values correctly.
* Fixed textile plugin not enabled by default after adding it as a plugin
* Comments plugin now correctly wordwraps
* Couple of linebreak fixes (*sigh*)
PLEASE TEST THE PLUGIN-STUFF! Needs to be verified working for rc2...
Index: serendipity_event_s9ymarkup.php
===================================================================
RCS file: /cvsroot/php-blog/serendipity/plugins/serendipity_event_s9ymarkup/serendipity_event_s9ymarkup.php,v
retrieving revision 1.2
retrieving revision 1.2.4.1
diff -u -d -r1.2 -r1.2.4.1
--- serendipity_event_s9ymarkup.php 18 Mar 2004 12:09:05 -0000 1.2
+++ serendipity_event_s9ymarkup.php 13 Apr 2004 10:01:14 -0000 1.2.4.1
@@ -21,7 +21,7 @@
function introspect(&$propbag)
{
global $serendipity;
-
+
$propbag->add('name', PLUGIN_EVENT_S9YMARKUP_NAME);
$propbag->add('description', PLUGIN_EVENT_S9YMARKUP_DESC);
$propbag->add('event_hooks', array('frontend_display' => true, 'frontend_comment' => true));
@@ -56,7 +56,7 @@
function generate_content(&$title) {
$title = PLUGIN_EVENT_S9YMARKUP_NAME;
}
-
+
function introspect_config_item($name, &$propbag)
{
@@ -69,7 +69,7 @@
function event_hook($event, &$bag, &$eventData) {
global $serendipity;
-
+
$hooks = &$bag->get('event_hooks');
if (isset($hooks[$event])) {
@@ -77,7 +77,7 @@
case 'frontend_display':
foreach ($this->markup_elements as $temp) {
- if ($this->get_config($temp['name']) != 'false' && isset($eventData[$temp['element']])) {
+ if (serendipity_db_bool($this->get_config($temp['name'], true)) && isset($eventData[$temp['element']])) {
$element = $temp['element'];
$eventData[$element] = $this->_s9y_markup($eventData[$element]);
}
@@ -86,7 +86,7 @@
break;
case 'frontend_comment':
- if ($this->get_config(COMMENT) != 'false') {
+ if (serendipity_db_bool($this->get_config(COMMENT, true))) {
echo PLUGIN_EVENT_S9YMARKUP_TRANSFORM . '<br />';
}
return true;
|