MyBB Community Forums

Full Version: [UPDATED][SEO] Simple TagCloud Plugin for myBB v 0.9a - Tag Cloud (beta)
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I'll publish 2 verions of plugin (size tags by frequence and radom size tags)
Hi
very thanks
Persian/Farsi language for 0.5b add to Post: #50
Thanks
OK, tags are not repeated anymore, but I'm getting tons of "Divide by zero" errors because $max_amount is always 0. After fixing that (divide by 1 if $max_amount is 0), then $size is 0, so the tags don't show up.
(2009-09-13, 01:38 AM)laie_techie Wrote: [ -> ]OK, tags are not repeated anymore, but I'm getting tons of "Divide by zero" errors because $max_amount is always 0. After fixing that (divide by 1 if $max_amount is 0), then $size is 0, so the tags don't show up.
if($max_amount == 0)
{
 // do the division by one here
}
else
{
 // do the division by $max_amount here;
}
Try newest verion, if Im not wrong it should work.
(Tnx Tom for help)

I have got a question, have somebody got better idea how to size tags
I don't think this is good script:
			$wielkosc = $exploded_tag[1];
			$stcp_size = $mybb->settings['stcp_size'];
			$perc = ($wielkosc * $stcp_size) / $max_amount;
			$perc = $perc - ($wielkosc * $wielkosc);
			$perc = ceil($perc);

			$size = $perc;
			$size = (int) $size;
Hi
Persian/Farsi language (Fully Persian):
[attachment=15334]

Persian/Farsi by Pars in www.MybbIran.com

Persian Information for Simple TagCloud Plugin in MybbIran Forum:
http://community.mybbiran.com/thread-171-post-434.html

Thanks
Looks good Smile

How many queries makes this plugin in each thread?
Thread one query

Index and forumdispaly - one tag - one query (if you got 300 tags per page 300 querys !! and I don't know what to do to make it beter :< )
Turkish Plugins
Download
[attachment=15336]
Turkish By bomfile
Zip password:www.mybbdestek.com
http://www.mybbdestek.com
http://forum.mybbdestek.com/Konu-basit-e...dece-md-de
Thanks.
(2009-09-13, 06:11 AM)Watt Wrote: [ -> ]Try newest verion, if Im not wrong it should work.
(Tnx Tom for help)

I have got a question, have somebody got better idea how to size tags
I don't think this is good script:
			$wielkosc = $exploded_tag[1];
			$stcp_size = $mybb->settings['stcp_size'];
			$perc = ($wielkosc * $stcp_size) / $max_amount;
			$perc = $perc - ($wielkosc * $wielkosc);
			$perc = ceil($perc);

			$size = $perc;
			$size = (int) $size;
What variable defines the max length, and is $size the maximum size of the tag? You could always do a strlen check and see if it's greater than $max_length.