bwanders / dokuwiki-strata

Strata - a Semi-Structured Data plugin for Dokuwiki
https://www.dokuwiki.org/plugin:strata
17 stars 8 forks source link

Multiple values for expressions with * can't be used #44

Closed boqapt closed 6 years ago

boqapt commented 6 years ago

When I use "filter*:..." expression I get an exception because the plugin uses for parsing "split" function which was removed in PHP 7.0. Just need to replace split->explode

PHP Fatal error: Uncaught Error: Call to u ndefined function split() in /var/www/html/dokuwiki/lib/plugins/strata/helper/syntax.php:1026\nStack trace:\n#0 /va r/www/html/dokuwiki/lib/plugins/strata/helper/syntax.php(983): helper_plugin_strata_syntax->_setPropertyValue(Array , 'ui', Array, 'filter', true, 'select, select', Array)\n#1 /var/www/html/dokuwiki/lib/plugins/strata/syntax/select .php(190): helper_plugin_strata_syntax->setProperties(Array, Array)\n#2 /var/www/html/dokuwiki/lib/plugins/strata/s yntax/select.php(116): syntax_plugin_strata_select->handleUI(Array, Array, Array)\n#3 /var/www/html/dokuwiki/inc/parser/handler.php(80): syntax_plugin_strata_select->handle('<table ?name ?c...', 5, 73, Object(Doku_Handler))\n#4 /var/www/html/dokuwiki/inc/parser/lexer.php(526): Doku_Handler->plugin('<table ?name ?c...', 5, 73, 'strata_table')\n#5 /var/www/html/dokuwiki/inc/parser/lexer.php(454): Doku_Lexer->_invokeParser('<table ?name ?c...', 5, 73)\n#6 /var/www/html/dokuwiki/inc/parser/lexer.php(411): Doku_Lexer->_dispatchTokens('', '<table in /var/www/html/dokuwiki/lib/plugins/strata/helper/syntax.php on line 1026, referer: http://localhost/dokuwiki/doku.php?id=start&do=draft PHP Fatal error: Uncaught Error: Call to u ndefined function split() in /var/www/html/dokuwiki/lib/plugins/strata/helper/syntax.php:1026\nStack trace:\n#0 /va r/www/html/dokuwiki/lib/plugins/strata/helper/syntax.php(983): helper_plugin_strata_syntax->_setPropertyValue(Array , 'ui', Array, 'filter', true, 'select, select', Array)\n#1 /var/www/html/dokuwiki/lib/plugins/strata/syntax/select .php(190): helper_plugin_strata_syntax->setProperties(Array, Array)\n#2 /var/www/html/dokuwiki/lib/plugins/strata/s yntax/select.php(116): syntax_plugin_strata_select->handleUI(Array, Array, Array)\n#3 /var/www/html/dokuwiki/inc/parser/handler.php(80): syntax_plugin_strata_select->handle('<table ?name ?c...', 5, 73, Object(Doku_Handler))\n#4 /var/www/html/dokuwiki/inc/parser/lexer.php(526): Doku_Handler->plugin('<table ?name ?c...', 5, 73, 'strata_table')\n#5 /var/www/html/dokuwiki/inc/parser/lexer.php(454): Doku_Lexer->_invokeParser('<table ?name ?c...', 5, 73)\n#6 /var/www/html/dokuwiki/inc/parser/lexer.php(411): Doku_Lexer->_dispatchTokens('', '<table in /var/www/html/dokuwiki/lib/plugins/strata/helper/syntax.php on line 1026, referer: http://localhost/dokuwiki/doku.php?id=start&do=draft

bwanders commented 6 years ago

Will fix this weekend.

bwanders commented 6 years ago

Fixed in 3871bc8f945d6b80b00870b61d5a3475d7010603. This was the only split I could find that was still in use.

Thanks for reporting!