Hello There, Guest! › Register

MySubscriptions 2.2 released.
Looking for a custom plugin for your site? Ask here for a quote.

Exclude BB code from posts
#1

When users do things like quoting, or posting a video, they easily bypass the character limit. Disabling BB code would fix this problem, and I've yet to see a plugin for it.

Could someone do this?
Reply
#2

You want to disable bbcode on every post?
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#3

I meant excluding it from the character count. I believe I already posted this under support, but I figured that the request section would be better. Feel free to close the other thread.
Reply
#4

Oh, it's impossible to write a plugin to do such thing (I'm remembering the code, that's why I'm saying that, I may not be 100% sure).
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#5

I think it is possible if we hook at datahandler_post_validate_thread, datahandler_post_validate_post.
Support PM's will be ignored. Exclamation
Plugins: Announcement Bars - Custom Reputation - Mark PM As Unread
Reply
#6

Probably yes, probably not.

Maybe removing "message_too_long" from $this->errors may work, but I haven't tried it.
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#7

(01-23-2013, 06:31 AM)Pirata Nervo Wrote: Oh, it's impossible to write a plugin to do such thing (I'm remembering the code, that's why I'm saying that, I may not be 100% sure).

Hmm. Hackforums has a plugin like this, but I believe Labrocca made it just for himself.
Reply
#8

Either that or he simply patched the MyBB code.
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply
#9

I think we aren't in the same page here Pirata Nervo Tongue

Upon post/thread validation you can strip the HTML/MyCode/Quotes from the $this->data['message'] variable, then count the remaining characters to validate it against the core settings for minimum and/or maximum characters.
Support PM's will be ignored. Exclamation
Plugins: Announcement Bars - Custom Reputation - Mark PM As Unread
Reply
#10

Well IIRC when you add something to datahandler_post_validate_post the validator has already run, thus you can't strip it and hope for it to work. However, you could turn off the error, strip BB code and then count the characters yourself and set the error if it goes over the limit Smile But this is only what my memory tells me.
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Reply




Users browsing this thread: 1 Guest(s)