Import from SMF and strange tags in text.
Hello, I have imported my forms from SMF, all went great, except one thing. Parts of text in all forum posts are wrapped in strange <tt> tags.
That results in different font on the front end – http://levelonetwinks.com/?topic=about-frostmourne
And when looking at the posts from WP admin, text editor I see this:
<b>Frostmourne</b> is an established guild (<b>level 25</b>) that has existed on the realm as both social and raiding venue for nearly 8 years.<tt><tt>We’re looking for mature, fun, yet dedicated people that will not only contribute to our progress but to the strong social aspect of our guild.<tt><tt>We have a fairly non strict age requirement of 18+.</tt></tt></tt></tt>
Removing them manually sorts the issue but that’s a lot of work hours to go through each topic and reply :S
I’ve tried a localhost import to the default WP theme, same thing 🙁
Would be grateful for any insight on what may be causing it, as I’d rather not spend the next two days going through them manually :p
The code /includes/admin/converters/SMF.php#L717 is replacing
</tt>and a quick lookup of the “teletype” HTML tag shows we should not really be using it all 😉
Can you post the HTML raw source of the post from SMF for me, this will allow me to see if it is currently doing it correctly, which I think it is per the details and screenshot below.
[sup]superscript[/sup]<br />[sub]subscript[/sub]<br />[tt]teletype[/tt]
bbPress Converted Source:
We probably should rather than converting them
</tt>convert them to a
<span style="font-family: monospace;"> This is a sample. </span>
Thank you for taking the time to reply. Was away for a couple of days.
Anyhow, the same topic in the smf install is here: http://frostmourne.co.uk/index.php?topic=16.0 – you should be able to view page source.
It’s just using bbcodes for formatting, not sure how SMF handles this from the backend.
[b]Frostmourne[/b] is (...) Apply [url=http://frostmourne.co.uk/index.php?action=form;n=2]HERE[/url]. If you have any questions or concerns, please feel free to contact any of our staff members. [hr] GM [list] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=16]Mafist[/url][/li] [/list]Officers [list] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=33]Shadowk[/url], [/li] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=43]Krybaybee (kirstykins)[/url],[/li] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=19]Auraguardian (Taichihamsta)[/url],[/li] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=27]Moondo[/url],[/li] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=27]Tranquilrage[/url][/li] [/list] [hr] Forum Admins [list] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=27]Moondo[/url],[/li] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=27]Tranquilrage[/url], [/li] [li][url=http://frostmourne.co.uk/index.php?action=profile;u=71]Starwatcher (Worganic)[/url][/li] [/list]
Thanks again, appreciate your help 🙂
As noted in your other topic, your replies here were marked as spam, I’ve unmarked them all as spam and deleted the duplicates.
Testing that same BBCode you have in your reply above (the one I left published) it does look like there is an error/conflict, I’ll take a look at this during the week and get back to you.
Again, apologies for your replies being caught by our spam filter. 🙂
I just did an import of an SMF forum to bbPress, and my posts have <tt><tt> where all my paragraph breaks were.
I don’t have any of these though, as shown by the other poster: </tt>
But I do have some individual <tt>’s
Any links in the posts also have [ class=”bbcode_url” ] attached to the end of the link.
<tt>Australian Electoral Commission<tt><a href="http://www.aec.gov.au/" class="bbcode_url">http://www.aec.gov.au/</a><tt>Enrolled etc
I am not entirely sure, but you might need to install a find and repplace plugin to remove unwanted characters in posts.
@abcdiamond A good DB search and replace plugin is https://wordpress.org/plugins/better-search-replace/
class="bbcode_url"could most likely be ignored as it’s only a CSS style
Strange that you have
</tt>, I’ll take a another look at these.
A quick look at the
We’re doing this:
// Replace '[tt]' with '<tt>' $SMF_markup = preg_replace( '/\[tt\]/', '<tt>', $SMF_markup ); // Replace '[/tt]' with '</tt>' $SMF_markup = preg_replace( '/\[\/tt\]/', '</tt>', $SMF_markup );
I’m wondering if your SMF forums used custom BBCode’s here? It looks like it was for URL’s where
class="bbcode_url"was being added to links, maybe also a custom BBCode for
[tt]was being used where no closing
[/tt]BBCode was required?
- You must be logged in to reply to this topic.