6.0.0-beta1
7/6/25

[#8156] Mediawiki tables not displaying correctly
Summary Mediawiki tables not displaying correctly
Queue Wicked
Type Bug
State Not A Bug
Priority 1. Low
Owners
Requester lfbm.andamentos (at) gmail (dot) com
Created 04/07/2009 (5934 days ago)
Due
Updated 04/16/2009 (5925 days ago)
Assigned 04/16/2009 (5925 days ago)
Resolved 04/16/2009 (5925 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
04/16/2009 10:27:27 PM Jan Schneider Comment #5
State ⇒ Not A Bug
Reply to this comment
Yes.
04/16/2009 10:09:55 PM Michael Rubinsky Comment #4
State ⇒ Feedback
Priority ⇒ 1. Low
Reply to this comment
Ok...so this isn't a horde bug, then? It's a PEAR bug, right?
04/11/2009 05:17:37 PM lfbm (dot) andamentos (at) gmail (dot) com Comment #3 Reply to this comment
There's a fix to make it work with php 2.6 and higher. It must be 
issued on PEAR package Text_Wiki_Mediawiki:



--- Text/Wiki/Parse/Mediawiki/Table.php.orig        2009-04-11 
13:50:19.000000000 -0300

+++ Text/Wiki/Parse/Mediawiki/Table.php        2009-04-11 13:54:20.000000000 -0300

@@ -153,11 +153,13 @@

          }

          $this->_countRows[$this->_level] = 
$this->_maxCells[$this->_level] = 0;

          $this->_countCells[$this->_level] = 
$this->_spanCells[$this->_level] = array();

+        $expsub = rtrim($expsub, "\n|-") . "\n|-";

          $sub = preg_replace_callback(

              $this->regexRows,

              array(&$this, 'processRows'),

              $expsub

          );

+        $sub = rtrim($sub, "\n|-");

          $param = array(

                  'type'  => 'table_start',

                  'level' => $this->_level,



More info: http://pear.php.net/bugs/bug.php?id=14346



Thanks
04/11/2009 04:52:52 AM lfbm (dot) andamentos (at) gmail (dot) com Comment #2 Reply to this comment
The funny thing is that it was working perfectly and has stopped
after some updatings. Since I have updated a lot of thing together, I
can't precise what component is causing the trouble.
What has broken it is php 5.2.9. If you use php 5.1.6, then tables 
work just fine.



Given this information, against what package should a bug be reported? 
Is it pear packages Text_Wiki and Text_Wiki_MediaWiki that are not 
working with php higher than 5.1.6 or is it php that has some bug?



Thanks
04/07/2009 02:27:02 AM lfbm (dot) andamentos (at) gmail (dot) com Comment #1
Priority ⇒ 3. High
Type ⇒ Bug
Summary ⇒ Mediawiki tables not displaying correctly
Queue ⇒ Wicked
Milestone ⇒
Patch ⇒ No
State ⇒ Unconfirmed
Reply to this comment
A simple table like this won't work:



{|

| Cell 1

| Cell 2

|}



(Mediawiki table markup syntax: 
http://www.mediawiki.org/wiki/Help:Tables#Simple_table)



It shows like:



| Cell 1

| Cell 2



Instead of the proper table.



The funny thing is that it was working perfectly and has stopped after 
some updatings. Since I have updated a lot of thing together, I can't 
precise what component is causing the trouble.



I think Pear packages Text_Wiki and Text_Wiki_Mediawiki can't be, 
because they are not updated since a long time... So nothing different 
even after pear upgrade-all.



So maybe it's something in Horde, framework or wicked, I don't know.



The reproduction of the problem is quite simple:



1. Install a fresh horde module and wicked;

2. Select on wicked setup the mediawiki format;

3. Create a simple table:



{|

| Test

|}



4. Preview or Save. It won't show correctly.



I'm using now the latest snapshots from 29/03/2009 (horde, framework 
and wicked).



Thanks

Saved Queries