vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   News integration and HTML on for the 1st post (https://vborg.vbsupport.ru/showthread.php?t=201149)

Ronny 01-09-2009 07:34 AM

News integration and HTML on for the 1st post
 
I'm about to write a news script integration for vBulletin 3.8. All the external part is so far done and tested with my 3.7 testinstallation, the only remaining question for me is now how to manage to display the news in vBulletin with full HTML. Well, i could turn on HTML for the "News" forums but then all the users could use HTML and i guess you all know that this could be verry bad. So i'm looking for the right hook in the forums display to show only the 1st post - the news post - in full HTML. All the vBulletin usergroup integration is done but this last tricky part is very hard for me to find out by myself. I'm also not so sure if that is even possible the way i want it to, i guess there is a reason why HTML can only be turnd on for a forum and not for users / groups.

If anyone can direct me in the right way or even better tell me the right hook i have to use, that would be perfect :) Maybe some one allready did that before?

Thanks allot!

Dismounted 01-09-2009 08:02 AM

This might be difficult - HTML is weeded out right at the start of processing, and there aren't many useful hooks before it. (At least I don't recall any.) What you could do is add your own BB code with external callback (see hook bbcode_fetch_tags) and use that tag with an ID or something as the parameter. Then in your callback function, use this ID to return the actual content.

Ronny 01-10-2009 03:16 PM

Thanks for the quick reply!

Not sure where vBulletin is actually checking the HTML premissions, i guess somewhere (showthread.php) starting from line 984 ... Maybe done by the vB_BbCodeParser class, i can only guess ;) So far i've no clue even where i could overwrite the HTML check directly in the vBulletin file.

Should there be this "#" in showthread.php line 1073 (3.8.0 US)?

I'm not giving up so fast but right now i just "convert" the HTML with the vBulletin HTML to BBCode function and don't care about the post format. Not a solution i really like and adding or changing the vBulletin BBCode to manage some basic picture positions works but i don't like it either.

Dose anyone has some deeper knowlage where the HTML check is "hidden"?

Dismounted 01-11-2009 04:52 AM

Quote:

Originally Posted by Ronny (Post 1707400)
Dose anyone has some deeper knowlage where the HTML check is "hidden"?

It is done in the BB code parser class, and it uses a direct check using a forum ID (the post information is not in focus, however, on second thought, you may be able to bring it into focus).

Ronny 01-11-2009 06:16 AM

Thanks.

Any idea if there will be soon a solution in vBulletin 3 or maybe 4 to set HTML rights for usergroups? I really would like such a feature! :)

Dismounted 01-11-2009 07:37 AM

If you are referring to a default feature, I do not know the answer to that question. However, it is unlikely any significant new features will be included in vBulletin 3.


All times are GMT. The time now is 01:00 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.00973 seconds
  • Memory Usage 1,720KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete