Hi everybody!
Here's a late Christmax present: I've found and fixed a small bug in
editpage.php that meant that pages reverted to old markup when someone
edited them :-/
The patch follows:
Index: editpage.php
===================================================================
RCS file: /cvsroot/phpwiki/phpwiki/lib/editpage.php,v
retrieving revision 1.49
diff -u -3 -r1.49 editpage.php
--- editpage.php 17 Dec 2002 18:32:48 -0000 1.49
+++ editpage.php 26 Dec 2002 14:01:44 -0000
@@ -352,8 +352,8 @@
if ($this->_currentVersion > $this->current->getVersion())
return false; // FIXME: some kind of warning?
- $is_new_markup = !empty($posted['markup']) && $posted['markup'] == 'new';
- $meta['markup'] = $is_new_markup ? 2.0: false;
+ $is_old_markup = !empty($posted['markup']) && $posted['markup'] == 'old';
+ $meta['markup'] = $is_old_markup ? false : 2.0;
$meta['summary'] = trim(substr($posted['summary'], 0, 256));
$meta['locked'] = !empty($posted['locked']);
$meta['is_minor_edit'] = !empty($posted['minor_edit']);
--
Martin Geisler My GnuPG Key: 0xF7F6B57B
See http://gimpster.com/ and http://phpweather.net/ for:
PHP Weather => Shows the current weather on your webpage and
PHP Shell => A telnet-connection (almost :-) in a PHP page.
|