Index: trunk/extensions/RecordAdmin/RecordAdmin_body.php |
— | — | @@ -351,7 +351,7 @@ |
352 | 352 | foreach ( array_keys( $this->types ) as $k ) { |
353 | 353 | $v = isset( $posted[$k] ) ? ( $this->types[$k] == 'bool' ? 'yes' : $posted[$k] ) : ''; |
354 | 354 | if ( !preg_match( "|\s*\|\s*$k\s*=|", $text ) ) $text .= "\n|$k=\n|"; # Treat non-existent fields as existing but empty |
355 | | - $i = preg_match( "|^\s*\|\s*$k\s*=\s*(.*?)\s*(?=^\s*[\|\}])|sm", $text, $m ); |
| 355 | + $i = preg_match( "|^\s*\|\s*$k\s*= *(.*?) *(?=^\s*[\|\}])|sm", $text, $m ); |
356 | 356 | $r[$k] = isset( $m[1] ) ? $m[1] : ''; |
357 | 357 | if ( $v && !( $i && $this->cmpCallback( $r[$k], $v, $operator[$k] ) ) ) $match = false; |
358 | 358 | } |
— | — | @@ -760,7 +760,7 @@ |
761 | 761 | */ |
762 | 762 | function valuesFromText( $text ) { |
763 | 763 | $values = array(); |
764 | | - preg_match_all( "|^\s*\|\s*(.+?)\s*=\s*(.*?)\s*(?=^\s*[\|\}])|sm", $text, $m ); |
| 764 | + preg_match_all( "|^\s*\|\s*(.+?)\s*= *(.*?) *(?=^\s*[\|\}])|sm", $text, $m ); |
765 | 765 | foreach ( $m[1] as $i => $k ) $values[$k] = $m[2][$i]; |
766 | 766 | return $values; |
767 | 767 | } |
Index: trunk/extensions/RecordAdmin/RecordAdmin.php |
— | — | @@ -11,7 +11,7 @@ |
12 | 12 | * @licence GNU General Public Licence 2.0 or later |
13 | 13 | */ |
14 | 14 | |
15 | | -define( 'RECORDADMIN_VERSION', '0.9.6, 2009-12-19' ); |
| 15 | +define( 'RECORDADMIN_VERSION', '0.9.7, 2009-12-19' ); |
16 | 16 | |
17 | 17 | $wgRecordAdminUseNamespaces = false; # Whether record articles should be in a namespace of the same name as their type |
18 | 18 | $wgRecordAdminCategory = 'Records'; # Category containing record types |