Bug tracker

BBcode re-parser (fix completed in vcs)

OK a few weeks back I added the STK to my board and used it to re-parse the bbcode on my board. This morning I had it brought to my attention that the reparse had eaten every post on my board which contained the
Code: Select all
[code=php][/code]
bbcode.

Obviously being two week old revision of the STK I figured you may have fixed this. So I just installed a fresh install of phpBB and the latest revision of the STK (294) at the time of posting this.

Now when re-parsing BBcode containing the
Code: Select all
[code=php][/code]
bbcode it does something different, it no longer eats the post, rather it just messes it up :)


So make a post such as http://www.ktuk.net/photobucket/Jackal/1265010664.JPG

Run the re-parser once and you get something which all looks fine http://www.ktuk.net/photobucket/Jackal/1265010665.JPG

However run the re-parser a second time and you get something not so nice :P http://www.ktuk.net/photobucket/Jackal/1265010907.JPG

and then everytime you run the parser afterwards the code becomes more messed up :)

Comments / History

Edited ticket

Action performed by karlsemple (Former Team Member) on Feb 1st 2010, 07:55

Edited ticket

Action performed by karlsemple (Former Team Member) on Feb 1st 2010, 07:56

Changed ticket status from "New" to "Awaiting information"

Action performed by Erik Frèrejean (Support Team Member) on Feb 1st 2010, 10:45

Posted by Erik Frèrejean (Support Team Member) on Feb 1st 2010, 10:45

The images turn up as a blank page for me :/. Could you attach the corresponding database entries for those posts?

Edited ticket

Action performed by karlsemple (Former Team Member) on Feb 1st 2010, 15:25

Posted by karlsemple (Former Team Member) on Feb 1st 2010, 15:47

Sorry about the images, something else I need to fix which I had forgotten was broken :p I am having one of those days when it comes to the internet. The links have been edited to be direct links so hopefully you will be able to see them now.

Could you attach the corresponding database entries for those posts?
I have made a post, taken a sql backup of the post before running the re-parser, then taken a sql backup of the same post after running the re-parser once, and then again taken a 3rd sql backup of the same post after the bbcode re-parser has been run a second time. All three files are in the attached zip so you can compare
sql_snapshots.zip (2.89 KB)

Assigned ticket to user "Erik Frèrejean"

Action performed by Erik Frèrejean (Support Team Member) on Feb 2nd 2010, 16:33

Posted by D¡cky (Support Team Member) on Feb 2nd 2010, 19:01

I found that by removing
Code: Select all
$row['post_text'] = utf8_encode(html_entity_decode($row['post_text']));
and
Code: Select all
set_var($row['post_text'], $row['post_text'], 'string', true);
it fixes Karl's problem. I am in the process of doing further testing.

Posted by Erik Frèrejean (Support Team Member) on Feb 2nd 2010, 19:27

I've created a script in the "develop" folder which seems to solves this issue. Its very basic and can only do one post at the time but it works for testing.

Changed ticket status from "Awaiting information" to "Fix in progress"

Action performed by Erik Frèrejean (Support Team Member) on Feb 3rd 2010, 14:39

Changed ticket severity from "Uncategorised/normal" to "Severe"

Action performed by Erik Frèrejean (Support Team Member) on Mar 1st 2010, 12:19

Changed ticket status from "Fix in progress" to "Awaiting information"

Action performed by Erik Frèrejean (Support Team Member) on Mar 1st 2010, 12:20

Posted by Erik Frèrejean (Support Team Member) on Mar 1st 2010, 12:20

Changed ticket to severe it seems the re-parser changes the "author" name in viewforum to "Guest" while leaving the link and colour correct. Anyone able to reproduce this behavior?

Posted by karlsemple (Former Team Member) on Mar 1st 2010, 13:23

Not seeing it on my test board..... at a quick glance (only had little play) it appears to be working ok

Linked ticket with changeset: r308

Action performed by Anonymous (I am too lazy to register) on Mar 1st 2010, 13:36

Changed ticket status from "Awaiting information" to "Fix completed in SVN"

Action performed by Erik Frèrejean (Support Team Member) on Mar 1st 2010, 13:55

Ticket details

Related SVN changesets