[request] convert HTML tags phpBB2 to BBcode phpBB3

Looking for a MOD? Have a MOD request? Post here for help. (Note: This forum is community supported; phpBB does not have official MOD authors)
Scam Warning
selimevets
Registered User
Posts: 12
Joined: Mon Dec 17, 2007 4:48 am

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by selimevets » Fri Jan 11, 2008 6:09 am

Also interested in such a mod. Have lots of old, converted phpBB2 posts with html that I'd like to convert to bbcodes so they regain their formatting.

User avatar
PCGUY112887
Registered User
Posts: 499
Joined: Thu Apr 01, 2004 12:39 am
Location: Illinois
Contact:

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by PCGUY112887 » Wed Feb 06, 2008 4:32 pm

x3, really need this MOD! I am very surprised that the converter didn't do this, since having HTML in posts was a totally legit option in v2, but then you move to v3 and your stuck with HTML displaying as text all over the place.

I saw the mod that allows you to use HTML with [html] tags, that's fine and dandy but we need something to convert all of our OLD posts to BB code.

thunderbb
Registered User
Posts: 3
Joined: Thu Feb 28, 2008 2:23 pm

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by thunderbb » Thu Feb 28, 2008 2:26 pm

Any solution with this problem?
I habe over 22.000 messages with HTML tags on my forum.
I need to convert them to BBCODE or any format that phpBB3 recognizes.

Has anybody find something??

Thanks

myshortpencil
Registered User
Posts: 2
Joined: Sat Apr 19, 2008 5:44 am

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by myshortpencil » Mon Apr 21, 2008 2:50 am

The failure to provide support for html coding in the data conversion from phpBB2 to BB3 is a shocking and serious blunder, regardless of how long and hard some group of people thought about it.

selimevets
Registered User
Posts: 12
Joined: Mon Dec 17, 2007 4:48 am

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by selimevets » Tue May 27, 2008 8:50 pm

Still interested in this MOD. Has anyone seen a solution, free or paid yet?

User avatar
SAFFLEUR
Registered User
Posts: 323
Joined: Thu Nov 24, 2005 5:56 am
Location: Lenoir NC
Contact:

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by SAFFLEUR » Wed May 28, 2008 3:46 am

selimevets wrote:Still interested in this MOD. Has anyone seen a solution, free or paid yet?
I've seen no covnersion but EXreaction has made a mod that enables HTML tags again in phpBB3. You can find this on his website Lithium Studios.

You'll need to donate to become a supporter and get the MOD, but what's five bucks?

selimevets
Registered User
Posts: 12
Joined: Mon Dec 17, 2007 4:48 am

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by selimevets » Wed May 28, 2008 12:10 pm

I agree, $5 is a good value, but I'm not interested in enabling HTML again. I'm on-board with the security BBCode offers, but with several years of HTML-enabled posts from phpBB2, I need the one-time conversion.

I'll try to do some reading on how BBCodes are generated and see if that will help me back into the code I need. I'd be satisfied with a SQL query that will get the job done rather than a full-fledged MOD. No doubt someone more familiar with phpBB3 would have an easier time of it than I will, but I'll nose around the tables and code until I get it :) If I make progress, I'll post my code here and maybe someone else can dress it up into something more robust.

User avatar
Phil
Former Team Member
Posts: 10403
Joined: Sat Nov 25, 2006 4:11 am
Name: Phil Crumm
Contact:

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by Phil » Thu Jun 05, 2008 5:51 pm

I think one of the biggest problems with this task is the fact that there isn't a set list of HTML that was enabled in phpBB2, and as such it would be very hard to write a converter that could convert everything as you'd have no way of knowing the syntax for all HTML tags ;) For example, the syntax for <img> is quite a bit different than <b>, etc., although if you wanted to strictly limit the converter to the standard BBCode within phpBB3, that wouldn't be too hard.
Moving on, with the wind. | My Corner of the Web

selimevets
Registered User
Posts: 12
Joined: Mon Dec 17, 2007 4:48 am

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by selimevets » Thu Jun 05, 2008 7:14 pm

That'd definitely be a nice start. Ultimately it'd be nice if you could somehow add to the list of codes supported and have it reparse posts. For example, I could have it run through and find all the <b>, and then go back through later to find all the <i>.

I've poked around the documentation, but can't find anything that explains (in english) how the bbcodes are parsed and stored. When I look at the posts in the database I see things like [b:abcdefgh] and [/b:abcdefgh]. Also observed that the bbcode_uid and bbcode_bitfield fields are set. I'm sure it's all for a reason, but from whree I'm sitting itd sure be nice to just have and in there - would certainly make a search/eplace easier :P

User avatar
Phil
Former Team Member
Posts: 10403
Joined: Sat Nov 25, 2006 4:11 am
Name: Phil Crumm
Contact:

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by Phil » Thu Jun 12, 2008 4:47 pm

I think I'll take a look at this. Could one of you maybe PM me a copy of your database with some HTML posts so I can have something to test it on?
Moving on, with the wind. | My Corner of the Web

tommekemc
Registered User
Posts: 457
Joined: Wed May 14, 2008 6:36 pm
Location: Belgium
Contact:

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by tommekemc » Thu Jun 12, 2008 6:49 pm

so basicly, you want to rewrite the messages in your database with bbcode.
This is possible, let's see :)
I don't know how the HTML came into your forums, but I do hope there is an UID with all of the posts (check in your DB, phpbb_posts, bbcode_uid.
If this exists, it is possible to replace your content, but it would take a lot of time (step 1: fetch from the DB, step 2: convert every tag known, step 3: any unknown tags should become htmlentities so they don't harm your forum, step 4: replacing the original text from your DB.
As some of you have more then 20.000 posts, I think you might just want to use a limit, and a temp row containing info about updated/not, so you can just refresh your PHP page and the query will continiue.

I hope I gave some good suggestiond, at the moment I'm in the middle of examinations, so creating a script of this size won't be possible, but I do hope I gave other programmers an idea of how they should work.
my sig
my projects

images deleted because of the 6kb (wtf?) rule...

User avatar
Phil
Former Team Member
Posts: 10403
Joined: Sat Nov 25, 2006 4:11 am
Name: Phil Crumm
Contact:

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by Phil » Thu Jun 12, 2008 7:09 pm

I've already got one written, actually. Working on packaging it right now.
Edit: Tada! ;)
Moving on, with the wind. | My Corner of the Web

DaannO
Registered User
Posts: 86
Joined: Mon Sep 17, 2007 11:24 am

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by DaannO » Thu Jun 12, 2008 10:03 pm

Im too looking for a way to enable full html for my mods and admins with [html][/html] tags

Like this old mod but then for phpbb3:
This MOD adds an HTML BBcode to your forum, which allows you to enter HTML tags yourself when posting a message. It is also possible to post JavaScript, Flash or Java objects, Forms, etc. You can even use other BBCode tags within an HTML block! Syntax is pretty simple: [html]text[/html]. While this BBCode is powerful, it is also somehow dangerous! By default, it is only allowed for the main board administrator. It can also be allowed for other Admins or members of a usergroup via ACP.
SAFFLEUR wrote:
selimevets wrote:Still interested in this MOD. Has anyone seen a solution, free or paid yet?
I've seen no covnersion but EXreaction has made a mod that enables HTML tags again in phpBB3. You can find this on his website Lithium Studios.

You'll need to donate to become a supporter and get the MOD, but what's five bucks?
Ive tried that one en it almost does the thins that i need, but it doenst put it between [html][/html] tags to enable html and when there is an enter in youre html code then it looks like a mess when you post it with that mod.

Please people, who is going to build this function for us?!

User avatar
Phil
Former Team Member
Posts: 10403
Joined: Sat Nov 25, 2006 4:11 am
Name: Phil Crumm
Contact:

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by Phil » Thu Jun 12, 2008 10:18 pm

That's outside the scope of this thread ;) This is for converting the HTML to BBCode.
Moving on, with the wind. | My Corner of the Web

DaannO
Registered User
Posts: 86
Joined: Mon Sep 17, 2007 11:24 am

Re: [request] convert HTML tags phpBB2 to BBcode phpBB3

Post by DaannO » Thu Jun 12, 2008 10:29 pm

Thnx, new topic then :)

Locked

Return to “[3.0.x] MOD Requests”