vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   How do I get this code to work with vb3.5? (https://vborg.vbsupport.ru/showthread.php?t=97158)

Wasim 09-29-2005 06:38 PM

How do I get this code to work with vb3.5?
 
In forumdisplay.php:

Find:
if ($thread['sticky'])
{
$threadbit = &$threadbits_sticky;
}

Replace with:
if ($thread['sticky'])
{
require_once('./includes/functions_bbcodeparse.php');
$thread['threadtitle'] = parse_bbcode($thread['threadtitle']);
$threadbit = &$threadbits_sticky;
}

Andreas 09-29-2005 06:44 PM

I am assuming this Code should parse BBCode in Titles of sticky Threads?

Wasim 09-29-2005 06:46 PM

Quote:

Originally Posted by KirbyDE
I am assuming this Code should parse BBCode in Titles of sticky Threads?

yes, basically it lets sticky threads have bbcode attributes. So we can make them color/bold.

Andreas 09-29-2005 07:03 PM

You can try this
threadbit_process
PHP Code:

if ($thread['sticky'])
{
    global 
$parser;
    if (!
$parser)
    {
        require_once(
DIR '/includes/class_bbcode.php');
        
$parser =& new vB_BbCodeParser($vbulletinfetch_tag_list());
    }
    
$thread['threadtitle'] = $parser->do_parse($thread['threadtitle'], falsefalsetruefalse);


However, you will run into problems with ugly display on many other pages.

Wasim 09-30-2005 11:34 PM

Thanks Kirby, but is this safe?

Wasim 10-02-2005 07:38 AM

Old Code I got and used on vbulletin 3.07 Doesnt work anymore.

In forumdisplay.php:

Find:
if ($thread['sticky'])
{
$threadbit = &$threadbits_sticky;
}

Replace with:
if ($thread['sticky'])
{
require_once('./includes/functions_bbcodeparse.php');
$thread['threadtitle'] = parse_bbcode($thread['threadtitle']);
$threadbit = &$threadbits_sticky;
}

Martz 10-02-2005 07:59 PM

I'm having the same problems since the bbcode parser seems to have changed into some sort of class, rather than just being an available function we used to use before :(

Good in the long run I guess, it just b0rked our old news system from the forums to the main site.

Got it fixed now :D Thanks for the thread Kirby.

Tip: if you are pulling from an external database, don't mix your variables!!

Wasim 10-02-2005 09:15 PM

Quote:

Originally Posted by Martz
I'm having the same problems since the bbcode parser seems to have changed into some sort of class, rather than just being an available function we used to use before :(

Good in the long run I guess, it just b0rked our old news system from the forums to the main site.

Got it fixed now :D Thanks for the thread Kirby.

Tip: if you are pulling from an external database, don't mix your variables!!

What do you mean pulling from an external database?

Kirby, it's not working for me... where exacty am i supposed to insert this code?

Andreas 10-02-2005 09:45 PM

Quoting myself:

Quote:

Originally Posted by KirbyDE
You can try this
threadbit_process


Wasim 10-03-2005 04:19 AM

Quote:

Originally Posted by KirbyDE
Quoting myself:

Im sorry for sounding dumb, but is that a template or a file?


All times are GMT. The time now is 01:57 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.01184 seconds
  • Memory Usage 1,737KB
  • 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_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete