Index: trunk/extensions/SemanticForms/includes/SF_FormClasses.inc |
— | — | @@ -295,9 +295,11 @@ |
296 | 296 | $email_type = $datatypeLabels['_ema']; |
297 | 297 | $float_type = $datatypeLabels['_num']; |
298 | 298 | $int_type = $datatypeLabels['_num']; |
299 | | - // just a placeholder until SMW 1.0 supports Boolean types - |
300 | | - // should be $datatypeLabels['_boo']; |
301 | | - $bool_type = 'boolean'; |
| 299 | + // some old versions of SMW 1.0 don't support Boolean types |
| 300 | + if (array_key_exists('_boo', $datatypeLabels)) |
| 301 | + $bool_type = $datatypeLabels['_boo']; |
| 302 | + else |
| 303 | + $bool_type = 'boolean'; |
302 | 304 | $date_type = $datatypeLabels['_dat']; |
303 | 305 | $enum_type = 'enumeration'; // not a real type |
304 | 306 | $page_type = $datatypeLabels['_wpg']; |
Index: trunk/extensions/SemanticForms/includes/SF_FormPrinter.inc |
— | — | @@ -51,9 +51,11 @@ |
52 | 52 | $float_type = $datatypeLabels['_num']; |
53 | 53 | $int_type = 'integer'; // placeholder - no longer exists |
54 | 54 | } |
55 | | - // just a placeholder until SMW 1.0 supports Boolean types - |
56 | | - // should be $datatypeLabels['_boo']; |
57 | | - $bool_type = 'boolean'; |
| 55 | + // some old versions of SMW 1.0 don't support Boolean types |
| 56 | + if (array_key_exists('_boo', $datatypeLabels)) |
| 57 | + $bool_type = $datatypeLabels['_boo']; |
| 58 | + else |
| 59 | + $bool_type = 'boolean'; |
58 | 60 | $date_type = $datatypeLabels['_dat']; |
59 | 61 | $enum_type = 'enumeration'; // not a real type |
60 | 62 | $page_type = $datatypeLabels['_wpg']; |