Notifications
Clear all

wpForo 1.x.x [Solved] User posted post that broke forum layout

3 Posts
2 Users
2 Likes
382 Views
Macky
Posts: 792
Topic starter
(@percysgrowroom)
Noble Member
Joined: 3 years ago

Hi, You may have just seen i posted about broken forum layout on a certain page.ย 

Well, I found the problem was in a certain users post. They had added some code to add a video and it messed with the page layout.ย 

Once i had deleted the post, everything went back to normal.

I dont think its right that code in users posts can have a effect on the lay out of the page? Is that a potential bug that needs fixing?

ย 

2 Replies
Robert
Posts: 9265
Admin
(@robert)
Support Team
Joined: 6 years ago

This can happen with any forum software. This is not a bug, this is the HTML programming language that is used by all browsers. If user copy an HTML content from other website and paste it in editor, and some <div> or other tags are not closed the forum layout will be broken in that topic. There is no way to scan copy/pasted HTML code and close all unclosed tags. And there is no way to filter those, because those are allowed and regular tags.

You should find that post in the forum database > wp_wpforo_posts table, edit the body and try to repair or strip the HTML. I'd recommend repair, because stripping HTML may remove images.

Repair HTML:
https://www.ranknotebook.com/tools/repair-html
https://htmltidy.net/

Strip HTML:
https://www.striphtml.com/

ย 

IMPORTANT: after fixing the HTML and updating the body field of that post in database, you should delete wpForo cache to see the result. The wpForo delete cache button is located in Dashboard > Forums > Dashboard admin page.

ย 

1 Reply
Macky
(@percysgrowroom)
Joined: 3 years ago

Noble Member
Posts: 792

@robert I just deleted it mate ๐Ÿ˜‰ 

Thanks for the info, much appreciated 

Share: