Support Request Template
What version of phpBB are you using? phpBB 3.3.13
What is your board's URL? not publicly accessible right now
Who do you host your board with? on "bare metal" in data center
How did you install your board? I used the download package from phpBB.com
What is the most recent action performed on your board? Fresh Install
Is registration required to reproduce this issue? No
Do you have any MODs installed? No
Do you have any extensions installed? Yes
What extensions do you have installed? StopForumSpam
What styles do you currently have installed? Carbon
What language(s) is your board currently using? default BE
Which database type/version are you using? MariaDB
What is your level of experience? New to phpBB but not PHP
What actions did you take (updating your board; installing a MOD, style or extension; etc.) prior to this problem becoming noticeable? Migrated from vb3, then manually set/fixed permissions for groups so everything is nice and clean again.
Please describe your problem. After converting an old forum with 2 million posts, some BBCode did not get converted properly. I'll give an example.
This is the post_text. The problem is that the quote doesn't show as a quotebox in the forum. The cause is simply the double quote around the name. When manually editing the post via the frontend and removing the doubled quotes around the author name, the preview shows it would "parse" properly into a quotebox.As this issue affects a couple hundred thousand posts, we don't feel like doing this manually, though. Fixing the quotes in the DB is easily done with a simple regexp_replace (and takes just over a minute), but that sadly does not translate to the posts being rendered properly in the forum. Purging cache did not help either.
I found that you can trigger a reparse via the CLI (https://www.phpbb.com/support/docs/en/3 ... -reparser/), but that also doesn't help. Assuming this is because the text already is considered parsed, I then tried to first unparse the post_text in the DB, leading to this value, which looks like "clean" bbcode text to me:I then ran the reparse CLI again for this postid, but it unexpectedly resulted in the exact same result as the first codeblock above (minus the extra double quotes, obviously), so still no luck.
So now I tried to just hit "preview"&"save" in the forum frontend to see what the post_text would look like then:Which is obviously quite a bit different result, and I'm unsure why there's such a discrepancy.
Now the question: Is there an easy way to get the desired result (bottom codeblock) after manipulating post_text via the DB? Or do I need to dig into the phpBB functions that generate/prepare the text and call that for every single DB row in PHP (which obviously will have atrocious performance)?
What version of phpBB are you using? phpBB 3.3.13
What is your board's URL? not publicly accessible right now
Who do you host your board with? on "bare metal" in data center
How did you install your board? I used the download package from phpBB.com
What is the most recent action performed on your board? Fresh Install
Is registration required to reproduce this issue? No
Do you have any MODs installed? No
Do you have any extensions installed? Yes
What extensions do you have installed? StopForumSpam
What styles do you currently have installed? Carbon
What language(s) is your board currently using? default BE
Which database type/version are you using? MariaDB
What is your level of experience? New to phpBB but not PHP
What actions did you take (updating your board; installing a MOD, style or extension; etc.) prior to this problem becoming noticeable? Migrated from vb3, then manually set/fixed permissions for groups so everything is nice and clean again.
Please describe your problem. After converting an old forum with 2 million posts, some BBCode did not get converted properly. I'll give an example.
This is the post_text. The problem is that the quote doesn't show as a quotebox in the forum. The cause is simply the double quote around the name. When manually editing the post via the frontend and removing the doubled quotes around the author name, the preview shows it would "parse" properly into a quotebox.
Code:
<t>[quote=""Spaitro""]Thank you so much!<br/><br/>Everything worked flawlessly once I installed the files in the game folder, and now it’s running perfectly. I’m incredibly grateful for all the support and solutions you provided—it made all the difference. Thanks again![/quote]<br/><br/>Thank you for reporting back. All the best and have fun!</t>
I found that you can trigger a reparse via the CLI (https://www.phpbb.com/support/docs/en/3 ... -reparser/), but that also doesn't help. Assuming this is because the text already is considered parsed, I then tried to first unparse the post_text in the DB, leading to this value, which looks like "clean" bbcode text to me:
Code:
[quote="Spaitro"]Thank you so much!Everything worked flawlessly once I installed the files in the game folder, and now it’s running perfectly. I’m incredibly grateful for all the support and solutions you provided—it made all the difference. Thanks again![/quote]Thank you for reporting back. All the best and have fun!
So now I tried to just hit "preview"&"save" in the forum frontend to see what the post_text would look like then:
Code:
<r><QUOTE author="Spaitro"><s>[quote="Spaitro"]</s>Thank you so much!<br/><br/>Everything worked flawlessly once I installed the files in the game folder, and now it’s running perfectly. I’m incredibly grateful for all the support and solutions you provided—it made all the difference. Thanks again!<e>[/quote]</e></QUOTE>Thank you for reporting back. All the best and have fun!</r>
Now the question: Is there an easy way to get the desired result (bottom codeblock) after manipulating post_text via the DB? Or do I need to dig into the phpBB functions that generate/prepare the text and call that for every single DB row in PHP (which obviously will have atrocious performance)?
Statistics: Posted by Senshi_x — Fri Nov 22, 2024 3:28 pm