vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Show Thread Enhancements - BBcode Manager 1.32 : New looks for your quote, html, php and code bbcodes ! (https://vborg.vbsupport.ru/showthread.php?t=120073)

cclaerhout 08-13-2006 09:02 PM

Quote:

Originally Posted by calorie
Thanks, here you go. :)

Whaou... i've looked your code and all i can say is that there is a big difference between us : i'm really a beginner :knockedout: I'm going to study your code and if i have questions i will send you a pm :D But for instance, let's upgrade !

P.S : thanks also for the english corrections ;)

cclaerhout 08-13-2006 09:20 PM

Your code is working great, but i'm found some problems with mine using the legacy postbit. Before update, i'm going to correct this.

Edit : in fact it's not a bug ; i've to precise something in the installation file. The 1.30 version will be release in a few minutes :)

cclaerhout 08-13-2006 10:09 PM

Version 1.30 released thanks to Calorie : the installation is now fully automatic ; you just have to upload product file and that's all (no need to edit php file anymore) ; the english translation is also better thanks to Calorie.

Good to know :
To avoid display problems, i strongly advice you to set the "Code Block Width" (available in you style options) to 100%. If you prefer pixels, choose a little value ; especually if you're using legacy postbit. Never enter "auto" otherwise it won't work.

Rickie3 08-13-2006 11:34 PM

Hi i went to do the upgrade but i'm getting this error when importing the product
Code:

Database error in vBulletin 3.5.4:

Invalid SQL:

### INSERT QUERY GENERATED BY fetch_query_sql() ###
INSERT INTO sg_plugin
        (`active`, `executionorder`, `title`, `hookname`, `phpcode`, `product`)
VALUES
        ('1', '5', 'Cache and Variables', 'cache_templates', '$bbcode_templates_array = array();\r\n$bbcode_image_extension = \'png\';\r\n$bbcode_intersect_array = array_intersect(array(\'bbcode_quote\',\'bbcode_code\',\'bbcode_php\',\'bbcode_html\'), $globaltemplates);\r\n\r\nif (!empty($bbcode_intersect_array))\r\n{\r\n        $quote_light = explode(\",\", str_replace(\' \', \'\', $vbulletin->options[\'quote_light\']));\r\n        $quote_dark = explode(\",\", str_replace(\' \', \'\', $vbulletin->options[\'quote_dark\']));\r\n        $quote_pastel = explode(\",\", str_replace(\' \', \'\', $vbulletin->options[\'quote_pastel\']));\r\n        $quote_simple = explode(\",\", str_replace(\' \', \'\', $vbulletin->options[\'quote_simple\']));\r\n        $quote_simple_tr = explode(\",\", str_replace(\' \', \'\', $vbulletin->options[\'quote_simple_tr\']));\r\n\r\n        if ($vbulletin->options[\'quote_vba\'] AND !$FIRSTPOSTID)\r\n        {\r\n                $quote_vba_forums = explode(\",\", str_replace(\' \', \'\', $vbulletin->options[\'quote_vba_forums\']));\r\n                if ($vbulletin->options[\'quote_vba_forums_all\'] OR in_array($forumid, $quote_vba_forums))\r\n                {\r\n                        $bbcode_templates_array = array(\'bbcode_quote_vba\',\'bbcode_code_vba\',\'bbcode_php_vba\',\'bbcode_html_vba\');\r\n                }\r\n        }\r\n        else if (in_array($style[\'styleid\'], $quote_light))\r\n        {\r\n                $bbcode_templates_array = array(\'bbcode_quote_light\',\'bbcode_code_light\',\'bbcode_php_light\',\'bbcode_html_light\');\r\n        }\r\n        else if (in_array($style[\'styleid\'], $quote_dark))\r\n        {\r\n                $bbcode_templates_array = array(\'bbcode_quote_dark\',\'bbcode_code_light\',\'bbcode_php_light\',\'bbcode_html_light\');\r\n        }\r\n        else if (in_array($style[\'styleid\'], $quote_pastel))\r\n        {\r\n                $bbcode_templates_array = array(\'bbcode_quote_pastel\',\'bbcode_code_pastel\',\'bbcode_php_pastel\',\'bbcode_html_pastel\');\r\n        }\r\n        else if (in_array($style[\'styleid\'], $quote_simple))\r\n        {\r\n                $bbcode_templates_array = array(\'bbcode_quote_simple\',\'bbcode_code_simple\',\'bbcode_php_simple\',\'bbcode_html_simple\');\r\n        }\r\n        else if (in_array($style[\'styleid\'], $quote_simple_tr))\r\n        {\r\n                $bbcode_templates_array = array(\'bbcode_quote_simple_tr\',\'bbcode_code_simple_tr\',\'bbcode_php_simple_tr\',\'bbcode_html_simple_tr\');\r\n        }\r\n\r\n        unset($quote_light, $quote_dark, $quote_pastel, $quote_simple, $quote_simple_tr, $quote_vba_forums);\r\n\r\n        if (($vbulletin->options[\'quote_iedetect\'] AND is_browser(\'ie\') AND !is_browser(\'ie\', 7)) OR $vbulletin->options[\'quote_extension\'] == 1)\r\n        {\r\n                $bbcode_image_extension = \'gif\';\r\n        }\r\n}\r\n\r\nif (!empty($bbcode_templates_array))\r\n{\r\n        $globaltemplates = array_merge($globaltemplates, $bbcode_templates_array);\r\n}', 'bbcodemanager');

MySQL Error  : Unknown column 'executionorder' in 'field list'
Error Number : 1054
Date        : Sunday, August 13th 2006 @ 08:32:32 PM
Script      : http://www.sats-general.com/forum/admincp/plugin.php
Referrer    : http://www.sats-general.com/forum/admincp/plugin.php?do=productadd
IP Address  : ************
Username    : Rickie3
Classname    : vB_Database


calorie 08-13-2006 11:52 PM

Quote:

Originally Posted by Rickie3
Database error in vBulletin 3.5.4:

The XML is in vB 3.6.0 format, so it won't work 'out of the box' on vB 3.5.4.

If you have a vB 3.5.x board, you'll need to edit the XML file prior to import:

Find these blocks and remove them:
Code:

        <!-- this is near the top -->

        <url />
        <versioncheckurl />
        <dependencies>
        </dependencies>

        <!-- this is near the bottom -->

        <helptopics>
        </helptopics>
        <cronentries>
        </cronentries>
        <faqentries>
        </faqentries>

Find two cases of this and change it:
Code:

        <!-- from this -->

        <plugin active="1" executionorder="5">

        <!-- to this -->

        <plugin active="1">

Then import the product XML file.

Rickie3 08-14-2006 12:16 AM

@calorie thankyou that fixed it:-)

Smoothie 08-14-2006 01:51 AM

Quick question. This affects new quotes only and not existing ones?

nix 08-14-2006 02:07 AM

I really wanted to try this out but usually stay away from hacks that need .php files edits. Since this update takes care of that I gave it a go! Uploaded files, imported and specified the style ID. But I don't see any changes.

Rickie3 08-14-2006 02:10 AM

@nix did you set up your options in the adminCP?

nix 08-14-2006 02:12 AM

Yes.

Rickie3 08-14-2006 02:20 AM

have you got a link to your site? this is how ive set mine up in the adminCP see screenshot

nix 08-14-2006 02:24 AM

Mines the same except I'm using the simple bbcode option. With styles 1 and 2. I read somewhere in here that they were suppose to revert templates. Is this necessary?

calorie 08-14-2006 02:26 AM

No, you don't need to revert templates. Try rebuilding post cache and/or setting cached post lifespan to zero.

nix 08-14-2006 02:33 AM

nope.

calorie 08-14-2006 02:40 AM

Quote:

Originally Posted by nix
... With styles 1 and 2 ...

Do you want it on the '9tndark' style? If so, that your styleid 3.

Smoothie 08-14-2006 02:41 AM

From what I've seen so far, this quote stuff only affects new quotes after you import the product and select either all forums or specify a forum. In other words under vBa Option - All Forums set to yes or below that specify a forum

calorie 08-14-2006 02:44 AM

Try setting cached post lifespan to zero.

nix 08-14-2006 02:47 AM

Quote:

Originally Posted by calorie
Do you want it on the '9tndark' style? If so, that your styleid 3.

Sorry its not on that board. Tried the vb setting. didn't work.

calorie 08-14-2006 02:54 AM

Do you see anything if you make a new post?

nix 08-14-2006 02:56 AM

nope. Samething.

Smoothie 08-14-2006 02:57 AM

Quote:

Originally Posted by calorie
Try setting cached post lifespan to zero.

I set it to zero and that seems to have worked. Does setting it to zero affect the load times of threads?

nix 08-14-2006 03:05 AM

I also tried the post lifespan to zero. Still doesn't work.

calorie 08-14-2006 03:47 AM

@nix: are you trying this on a vB 3.5 board? If so, did you do this?

@Smoothie: yes, in that it parses on the fly, but try the following. Import the attached via ACP -> Plugins & Products -> Download / Upload Plugins, reset cached post lifespan, and rebuild post cache. A couple caveats about the attached: untested and GIF is forced as end user browser is unknown.

For vB 3.5 people, do the following before importing the attached plugin:
Code:

<!-- replace this -->
        <plugin active="1" executionorder="5" product="bbcodemanager">
<!-- with this -->
        <plugin active="1" product="bbcodemanager">


nix 08-14-2006 03:51 AM

No its 3.6 gold.

calorie 08-14-2006 03:56 AM

For the style IDs that you have, search for bbcode in the template title. What do you see?

nix 08-14-2006 04:06 AM

bbcode_code_light
bbcode_code_pastel
bbcode_code_printable
bbcode_code_simple
bbcode_code_simple_tr
bbcode_code_vba

nix 08-14-2006 04:08 AM

Okay, I just figured out what it is. I doesn't work with this plugin

Plugin Based Template Cache

calorie 08-14-2006 04:09 AM

Do you see these anywhere?
  • bbcode_code
  • bbcode_code_printable
  • bbcode_html
  • bbcode_html_printable
  • bbcode_php
  • bbcode_php_printable
  • bbcode_quote
  • bbcode_quote_printable

nix 08-14-2006 04:14 AM

Yes those are all there. See my previous post. Its a conflict with that plugin.

calorie 08-14-2006 04:20 AM

@nix: try setting the Execution Order for the 'Template Cache' plugin from the 'Plugin Based Template Cache' mod to a number greater than five, so that the plugin from this mod runs first in the cache_templates hook location.

Smoothie 08-14-2006 04:25 AM

Quote:

Originally Posted by calorie
@Smoothie: yes, in that it parses on the fly, but try the following. Import the attached via ACP -> Plugins & Products -> Download / Upload Plugins, reset cached post lifespan, and rebuild post cache. A couple caveats about the attached: untested and GIF is forced as end user browser is unknown.

Hi calorie,

Where in the admin cp is the rebuild post cache function? And what do you mean that GIF is forced as an end user browser is unknown?

Smoothie 08-14-2006 04:31 AM

I noticed a slight problem, not sure if it's on my end or not. I have vBa Option - All Forums set to no and below that I have vBa Option - Forum IDs set to one forum. However the new look quote appears in all forums....

calorie 08-14-2006 04:56 AM

Try setting 'vBa Option' to yes, 'vBa Option - All Forums' to no, and enter the forum ID in the 'vBa Option - Forum IDs' setting. For 'Rebuild Post Cache' go to ACP -> Maintenance -> Update Counters -> Rebuild Post Cache, but you'll only see it if 'Cached Posts Lifespan' is not zero.

Oh, and GIF is forced because it's the admin who rebuilds post cache, via the admin's browser, but not everyone has the same browser as the admin, so to avoid any IE/PNG issues, GIF is forced.

Smoothie 08-14-2006 05:03 AM

Quote:

Originally Posted by calorie
Try setting 'vBa Option' to yes, 'vBa Option - All Forums' to no, and enter the forum ID in the 'vBa Option - Forum IDs' setting. For 'Rebuild Post Cache' go to ACP -> Maintenance -> Update Counters -> Rebuild Post Cache, but you'll only see it if 'Cached Posts Lifespan' is not zero.

Oh, and GIF is forced because it's the admin who rebuilds post cache, via the admin's browser, but not everyone has the same browser as the admin, so to avoid any IE/PNG issues, GIF is forced.

vBa Option set to yes?

Quote:

vBa Option = Choose yes if you want to use a special vBadvanced bbcode set in the first message of a topic.

calorie 08-14-2006 05:06 AM

Best I can say on that one is to try it, as I don't use vBa CMPS. ;)

Smoothie 08-14-2006 05:10 AM

Ok, that did not work. I now see old style quotes in all forums. Even in the forum I specified as the one to have the new style quotes.

calorie 08-14-2006 05:18 AM

It's hard for me to say exactly, as I don't use vBa CMPS, but try 'vBa Option' as no and then rebuild post cache.

Smoothie 08-14-2006 05:26 AM

Quote:

Originally Posted by calorie
It's hard for me to say exactly, as I don't use vBa CMPS, but try 'vBa Option' as no and then rebuild post cache.

I don't use vBAdvanced either. Something in the settings isn't working right. I have it set to no for all forums and have specified a single forum to allow it. When I post in the forum that I have allowed, it works fine. When i post in the other forums which aren't allowed, it still works with the new style quote.

Unless I'm reading this wrong, the new style quote should only appear in the forum I have sepcified, not in any of the others.

calorie 08-14-2006 05:38 AM

Without vBa installed, then 'vBa Option' and 'vBa Option - All Forums' should be no and 'vBa Option - Forum IDs' should be blank. There isn't an option to set the new style quotes on a per forum basis, but it's possible by editing the 'Cache and Variables' plugin:
Code:

if (!empty($bbcode_intersect_array) AND $forumid == 5)

Smoothie 08-14-2006 06:07 AM

Quote:

Originally Posted by calorie
Without vBa installed, then 'vBa Option' and 'vBa Option - All Forums' should be no and 'vBa Option - Forum IDs' should be blank. There isn't an option to set the new style quotes on a per forum basis, but it's possible by editing the 'Cache and Variables' plugin:
Code:

if (!empty($bbcode_intersect_array) AND $forumid == 5)

Haha! Ya know, that's my bad. I'm a dummy. I didn't read any of that vBa stuff correctly. It didn't sink in until just now when you mentioned vBa installed.


All times are GMT. The time now is 10:26 PM.

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.01774 seconds
  • Memory Usage 1,835KB
  • 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
  • (6)bbcode_code_printable
  • (10)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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