Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.7 > vBulletin 3.7 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Global Tag Cloud in Side Bar or Anywhere Details »»
Global Tag Cloud in Side Bar or Anywhere
Version: 1.03, by lafsunlmtd lafsunlmtd is offline
Developer Last Online: Jul 2013 Show Printable Version Email this Page

Category: Miscellaneous Hacks - Version: 3.7.x Rating:
Released: 04-27-2008 Last Update: 07-16-2008 Installs: 139
Uses Plugins Template Edits
Re-useable Code Translations  
No support by the author.

What this plugin does

This plugin lets you call the tag cloud on any page. We wanted a tag cloud in a side column on our forum, and also the freedom to call it from within any template.

Live Demo

You can view the plugin in action on AdminFusion

Installation Instructions

1. Login in to the AdminCP -> Plugins and Products -> Manage Products
2. Click the Add/Import Product link at the bottom of the page and browse to the plugin's xml file.
3. Add the following variable where ever you want the tag cloud to appear:

Code:
$vbcloud
4. If you want to display just the cloud (i.e. without the category) open up the tag_cloud_search template and replace everything with the code below:

Code:
 
<if condition="THIS_SCRIPT != tags">
$cloud[links]
<else />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
	<td class="tcat">
		<div class="smallfont" style="float:$stylevar[right]"><phrase 1="$cloud[count]">$vbphrase[these_are_the_x_most_used_thread_tags]</phrase></div>
		$vbphrase[tag_cloud]
	</td>
</tr>
<tr>
	<td class="alt1" style="text-align:justify">$cloud[links]</td>
</tr>
</table>
</if>
Version Information:
1.01 -- Updated to make compatible with Vbulletin Blog
1.02 -- Script rewrite. Fixed time stamp issue, blog issue and other minor problems.
1.03
Now returns the most popular tags as opposed to the most searched for tags.
Some minor optimizations made.
Instructions revised (uses tag_cloud_box template instead of tag_cloud_search)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 05-01-2008, 02:00 PM
Alfa1's Avatar
Alfa1 Alfa1 is offline
 
Join Date: Dec 2005
Location: Netherlands
Posts: 3,537
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Please add the function to show only forum specific tags are shown. i.e. tags that are used in the forum that the tag cloud is in. That would have a very nice effect on SEO.
Reply With Quote
  #13  
Old 05-01-2008, 07:02 PM
soundbarrierpro soundbarrierpro is offline
 
Join Date: Nov 2007
Posts: 767
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I already have Ultimate Side Columns implemented. Can I add this code to one of the side column blocks in ACP? Will it still work?
Reply With Quote
  #14  
Old 05-03-2008, 05:16 PM
cihangir's Avatar
cihangir cihangir is offline
 
Join Date: Oct 2001
Posts: 22
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i have been using this plugin and i like it much, but it is not compatible with the vbulletin-blog add-on.

here is the copy of the error message:

PHP Code:
Database error in vBulletin 3.7.0:

Invalid SQL:

               (
                       
SELECT COUNT(*) AS total,
                       
FROM_UNIXTIME(dateline - , '%c-%e-%Y') AS period
                       FROM blog 
AS blog

                       WHERE state IN
('visible''moderation''deleted') AND dateline >= 1208728800 AND dateline 1209832470
                       GROUP BY period
               
UNION (
                       
SELECT COUNT(*) AS total,
                       
FROM_UNIXTIME(dateline - , '%c-%e-%Y') AS period
                       FROM blog 
AS blog
                       WHERE blog
.userid AND dateline >= 1208728800 AND dateline 1212357600
                       GROUP BY period
               
);

MySQL Error   You have an error in your SQL syntaxcheck the manual that corresponds to your MySQL server version for the right syntax to use near ' '%c-%e-%Y') AS period
                       FROM blog AS blog

                       WHERE state IN('
visible', 'mo' at line 3
Error Number  : 1064
Request Date  : Saturday, May 3rd 2008 @ 06:34:30 PM
Error Date    : Saturday, May 3rd 2008 @ 06:34:30 PM
Script        : http://forum.zoque.net/blog.php
Referrer      : http://forum.zoque.net/
Classname     : vB_Database
MySQL Version : 5.0.51a-0.dotdeb.1-log 
Reply With Quote
  #15  
Old 05-04-2008, 07:14 AM
lafsunlmtd lafsunlmtd is offline
 
Join Date: Jul 2005
Posts: 78
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

am looking into vb-blog compatability
Reply With Quote
  #16  
Old 05-04-2008, 09:53 AM
MiahBeSmokin420 MiahBeSmokin420 is offline
 
Join Date: May 2007
Location: Ohio
Posts: 311
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

HERE IS THE FIX FOR VB BLOGS

ok i though i would share this

but for everyone getting the error when you go to view blogs

this is what you need to do to fix that

go to plugin manager

look for Cloud > Global Start

then replace everything with :

HTML Code:
if (THIS_SCRIPT == 'blog' OR THIS_SCRIPT == 'blog_usercp' OR THIS_SCRIPT == 'blog_subscription' OR THIS_SCRIPT == 'blog_search' OR THIS_SCRIPT == 'blog_search' OR THIS_SCRIPT == 'blog_report' OR THIS_SCRIPT == 'blog_post' OR THIS_SCRIPT == 'blog-newattachment' OR THIS_SCRIPT == 'blog_inlinemod' OR THIS_SCRIPT == 'blog_callback' OR THIS_SCRIPT == 'blog_attachment' OR THIS_SCRIPT == 'blog_ajax' OR THIS_SCRIPT == 'blog_external') {      
    } else {
$vbulletin->datastore->fetch(array('tagcloud'));
$vbulletin->templatecache['tag_cloud_box'] = str_replace('$vbphrase[tag_cloud]', 'Tag Cloud', $vbulletin->templatecache['tag_cloud_box']);

require_once(DIR . '/includes/functions_search.php');
$tag_cloud = fetch_tagcloud('usage');
if ($tag_cloud)
{
    eval('$headinclude .= "' . fetch_template('tag_cloud_headinclude') . '";');
}
 }
that should solve all problems with the errors on the blogs page cause it fixed it on mine

remember to make a txt copy of what was there before you change it

although the only thing that i did was added a if command to make it so it wont run the product on the blog page


the creator of this mod should edit the files so that this is built into the mod since you really dont need a cloud in the blogs anyways

hope that helps people enjoy
Reply With Quote
  #17  
Old 05-04-2008, 05:47 PM
FLMom's Avatar
FLMom FLMom is offline
 
Join Date: Feb 2006
Location: Florida
Posts: 386
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks! Installing now
Reply With Quote
  #18  
Old 05-04-2008, 06:09 PM
FLMom's Avatar
FLMom FLMom is offline
 
Join Date: Feb 2006
Location: Florida
Posts: 386
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK I got it to work, but I can't see the text because it is too light of a color. How can I change the color so it's readable?

Thanks!
Reply With Quote
  #19  
Old 05-06-2008, 02:12 AM
jeff-- jeff-- is offline
 
Join Date: Mar 2006
Location: Michigan, US
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

A quick fix would be to make a new class with whichever color you want links to be (presumably the same as your forum links) and just apply a div around the $tag_cloud with that class.

After looking at your forum a better idea would be to follow step number 4 in the mod instructions where you replace tag_cloud_box with that code and make your own sidebar block instead of using the mod's code so that it will follow your css.
Reply With Quote
  #20  
Old 05-06-2008, 03:23 AM
lafsunlmtd lafsunlmtd is offline
 
Join Date: Jul 2005
Posts: 78
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ok updated with vb blog compatibility. Thanks for the quick code fix
Reply With Quote
  #21  
Old 05-06-2008, 01:57 PM
RetroDreams RetroDreams is offline
 
Join Date: Nov 2002
Posts: 238
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Works as expected.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:07 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05441 seconds
  • Memory Usage 2,326KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_code
  • (1)bbcode_html
  • (1)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete