|
Joined: May 2001
Posts: 1,042 Likes: 7
Moderator
|
Moderator
Joined: May 2001
Posts: 1,042 Likes: 7 |
Modification Name: VIPHTML Author(s): Brett Description: VIPHTML™ allows admins/mods or special people to post html in forums where it is disabled for the average person. Demo: n/a cp mod Download Link: https://www.ubbdev.com/ubb/upload/00006378/VIPHtml6.7.txt Credits: Greg Hard Shoutouts: Gizzy (2 left  ) After installation, the forum has to be set to only admins/vips, which is located in the permissions tab on details of each forum. Once this is enabled, admins/megamods/mods are automatically enabled. To enable special regular users, you would need to open each of their profile from the cp, click on the permissions tab, and under the forum list to add them as moderators, there is another forum list to specifically give them privilages to each forum's use of HTML. This by no way means, that it disables the HTML filter. It still goes through the same checks as before, but only when you put html tags, they actually execute and not print.
|
|
|
|
Joined: May 2001
Posts: 1,042 Likes: 7
Moderator
|
Moderator
Joined: May 2001
Posts: 1,042 Likes: 7 |
I had some logic errors in the actual checking. Updated TXT file, and the only replacement goes into the one part in ubb_lib_posting.cgi. (So just replace what you had in before with the new one  )
|
|
|
|
Joined: Jan 2000
Posts: 5,834 Likes: 20
UBBDev Owner Time Lord
|
UBBDev Owner Time Lord
Joined: Jan 2000
Posts: 5,834 Likes: 20 |
Hey, for once I found a bug and it wasn't running on my forum!
|
|
|
|
Joined: May 2001
Posts: 684
Code Monkey
|
Code Monkey
Joined: May 2001
Posts: 684 |
Great Hack!!!! ...but where can I build in new html-tags?
|
|
|
|
Joined: May 2001
Posts: 684
Code Monkey
|
Code Monkey
Joined: May 2001
Posts: 684 |
Why does some html tags not work?
|
|
|
|
Joined: May 2001
Posts: 1,042 Likes: 7
Moderator
|
Moderator
Joined: May 2001
Posts: 1,042 Likes: 7 |
The hack doesn't affect the way ubb translates html. If you were to take this hack out, and turn html on, it would do the same thing. What tag are you trying to use?
|
|
|
|
Joined: Mar 2001
Posts: 7,394
Admin / Code Breaker
|
Admin / Code Breaker
Joined: Mar 2001
Posts: 7,394 |
APPLET BODY EMBED FRAME FRAMESET HTML IFRAME LAYER LINK ILAYER META OBJECT SCRIPT STYLE NOSCRIPT NOEMBED NOFRAMES FORM XMP HEAD
That's the list of HTML tags UBB won't process, as well as PHP tags, ASP tags and tags with parenthesis, ( ) in them.
|
|
|
|
Joined: May 2001
Posts: 684
Code Monkey
|
Code Monkey
Joined: May 2001
Posts: 684 |
I want to use Ilayer and applet, is ther no chance to build this in?
|
|
|
|
Joined: Mar 2001
Posts: 7,394
Admin / Code Breaker
|
Admin / Code Breaker
Joined: Mar 2001
Posts: 7,394 |
You can remove ILAYER and APPLET from the list in ubb_lib.cgi, but it's really not recommended if you don't trust the people you let use HTML completely. (open ubb_lib.cgi, search for "ILAYER". you'll see both of them in the same line)
|
|
|
|
Joined: Jan 2003
Posts: 3,456 Likes: 2
Master Hacker
|
Master Hacker
Joined: Jan 2003
Posts: 3,456 Likes: 2 |
Brett, one bug I've been getting.
This doesn't take into account $is_html, meaning the you can't use html in other places, like the CP.
|
|
|
|
Joined: May 2001
Posts: 1,042 Likes: 7
Moderator
|
Moderator
Joined: May 2001
Posts: 1,042 Likes: 7 |
Your right. Well $is_html is just the wording, in a forum with vip, it would say you couldn't still even though you could. TXT updated. The only changes: in ubb_lib_posting.cgi
find:
if ($_[0] eq 'is') {
replace with:
if ($_[0] eq 'is' || $_[0] eq 'vip') {
|
|
|
|
Joined: Dec 2003
Posts: 40
Member
|
Member
Joined: Dec 2003
Posts: 40 |
Uh-oh, I think I found a bug. When I have html in the forum description (a link, for instance), the tags are converted to text-- in other words, I'm ending up with <A HREF="http://www.mydomain.com/">CLICK HERE</A> , where it should be CLICK HERE--and if I go into the CP and fix it, it changes it right back.
|
|
|
|
Joined: Jan 2003
Posts: 3,456 Likes: 2
Master Hacker
|
Master Hacker
Joined: Jan 2003
Posts: 3,456 Likes: 2 |
Originally posted by Nate: Uh-oh, I think I found a bug. When I have html in the forum description (a link, for instance), the tags are converted to text-- in other words, I'm ending up with CLICK HERE , where it should be CLICK HERE--and if I go into the CP and fix it, it changes it right back. do what Brett said, that'll fix it
|
|
|
|
Joined: Dec 2003
Posts: 40
Member
|
Member
Joined: Dec 2003
Posts: 40 |
Yes, I had done what Brett said in ubb_lib_posting when I did the initial install, but the problem still occurs. I verified that the mod is installed properly and precisely, also.
I'm putting simple HTML tags (font size, center)in the "Forum Introduction" section in the CP Forum Summary Options.
Sometimes I can get the HTML to stay as HTML for a short while, but after a few posts are made in one of the forums by a VIP using HTML tags, the tags on the main page revert back to text.
|
|
|
|
Joined: Jan 2003
Posts: 16
Junior Member
|
Junior Member
Joined: Jan 2003
Posts: 16 |
i installed this hack... but how can i do to allow html signatures for admin or authorized members ?
|
|
|
|
Joined: Jan 2000
Posts: 5,834 Likes: 20
UBBDev Owner Time Lord
|
UBBDev Owner Time Lord
Joined: Jan 2000
Posts: 5,834 Likes: 20 |
I believe an option is added to the editing members section of the control panel
|
|
|
|
Joined: Aug 2000
Posts: 178
Member
|
Member
Joined: Aug 2000
Posts: 178 |
He is right, there is an issue with this portion
# If HTML is not enabled, disable it
# VIP HTML my @user_profile = &OpenProfile($user_number); my @good_forums = split(/\, /, $user_profile[67]) if $user_profile[67]; my $authority_bool = ($user_profile[8] eq 'Administrator' || $user_profile[8] eq 'MegaModerator' || $user_profile[8] eq 'Moderator'); my $g = 0; foreach(@good_forums) { if($good_forums[$_] eq $_) { $g = 1; last; } } if (((($user_profile[67] && $g ne 1) || $authority_bool) && $vars_forums{$in{f}}->[4] eq 'vip') || ($vars_forums{$in{f}}->[4] eq 'is' && $authority_bool)) { } else { $message =~ s/</</g; $message =~ s/>/>/g; } #end if
If I add that (which allows the actual NO HTML bypass), forum descriptions are fubar'd.
|
|
|
Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.
Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
|
|
Posts: 69
Joined: January 2001
|
|
Forums63
Topics37,575
Posts293,931
Members13,824
|
Most Online6,139 Sep 21st, 2024
|
|
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
|
|
|
|