Blogging tips & www social trends
10 Apr
Category Cloud 1.6 is the latest release of Category Cloud, a wordpress plugin that shows categories as a colored tag cloud. You can see it in the sidebar at www.mapelli.info.
<?php if (function_exists('category_cloud')) category_cloud();?> where you want your category cloud to appear
Category Cloud can be customized via a style sheet, adding a category_cloud entry.
Here’s mine:
#category_cloud {
margin-left:20px;
margin-right:5px;
padding: 0px;
text-align: justify;
line-height: auto;
}
also, you can use the before and after fields in the option page to add further customization, e.g. by adding <span> or <li> tags before and after each category, and use css to restyle them.
You can add “additional” tag clouds in a page by calling the category_cloud() function with a parameter, for example you can show the top 5 categories with
<?php
$a = "ccloud_smallest=8&ccloud_largest=22&ccloud_order=POP&ccloud_numitem=5";
category_cloud($a);
?>
here are the valid variables you can use and what they means:
ccloud_smallest is the smallest font size in the resulting tag cloudccloud_largest is the largest font size in the resulting tag cloudccloud_unit is the unit that it’s used for the font, can be one of
ccloud_exclude is a list of the excluded categories IDs, something like “1, 3, 15″, or you can use ALL to exclude all the categoriesccloud_include is a list of the categories to include, something like “1, 3, 5″ccloud_subof is a list of the categories to search for subcategories to include. e.g. using “15, 3″ will display a tag cloud with the subcategories of category 15 and 3ccloud_showcount displays or hides the number of posts in each category. Valid values are
ccloud_order is the order of the tags in the resulting tag cloud, can be one of
ccloud_mincount is the minimum number of posts a category must have to appear in the resulting tag cloudccloud_numelements the number of categories to showccloud_before what to put before each categoryccloud_after what to put after each categoryccloud_startcol the color for the categories with less postsccloud_endcol the color for the categories with more postsI love them, so please don’t be shy and write something down here! :)
Also, if you write a comment and leave the “notify me of followup comments via e-mail” option checked, you will be mailed when bugs, feature requests or new versions are posted.
110 Responses for "Category Cloud 1.6 - Wordpress Plugin"
[…] This is not the latest version! you may be intrested in the latest version of category cloud […]
[…] This is not the latest version! you may be intrested in the latest version of category cloud […]
Getting closer to what I was looking for! The update looks good, but there is still one thing I would like to be able to do… exclude a category if there are children, but still display the children. for example, if this is what my categories look like:
- Food
—– Breakfast
—– Lunch
—– Dinner
- Friends
- Trips
- Animals
—– Cats
—– Dogs
Then I would like the following categories in the cloud. (Breakfast, Lunch, Dinner, Friends, Trips, Cats, Dogs). The categories of Animals, and Food would not display.
You can add animals and food in “subcategories of”, then set exclude to ALL, and put in include friends and tips ids…
or, if you don’t have posts in animals and food categories, you can simply set the minimum post count to 1…
I Hope this helps :)
[…] I have changed to the Category Cloud plugin as the weighted categories plug in discussed here hasn’t been updated for the latest […]
Close enough, thanks!
Woohoo! Figured out the problem of my cloud showing up as a list, Francesco. I had the cloud being called inside a page (using runphp)… where I should have had the code in a page template. One of the guys on the wordpress support forum pointed out it was WP itself that was adding the break tags. Changed methods and tada, works now. :)
Thought I should come back and post in case anyone else makes the same mistake. Thanks for the plugin Francesco.
Cheers, Sam.
Francesco, you are a saint. Have a look at the miracle clouds you made possible at http://www.barack-obama.tv .
Having the subcategories clouds is the best human invention since the chair!
Now you can retire.
Sam,
I’m happy you found the solution! Thanks for posting it here, it can be useful for the community :)
Borok,
great job, your colored clouds are really cool!
…but I don’t think I’m gonna retire that soon ;)
Wonderful, Get ready to download and update on my blog ^_*
How would I get the post count to show up in the link title like before, but not in the link itself? I like knowing the post count, just not in such a (large :)) visible way.
[…] tips & www social trends « Category Cloud 1.6 Apr 17, 2007 at 10:53 pm about blogging, tips (No Ratings Yet) Loading […]
Jeidai,
That’s no longer possible, sorry.
You have to edit the plugin by yourself, or wait for the next release :)
Interesting plug-in. I can see tat you blog a lot about blogging.
I cannot find the download link :( Can anyone give me a link to the zip-file?
fixed. problems with the download manager
Hey there, cool plug~ just a note, for the html to validate if you use li’s as the before and afters, you’re going to need a parent ul for them to live in.
Also, the spans used for the inline styles then need to be inside the li’s and not wrapped around them.
$ccloud_before span /span $ccloud_after
(above code just high level, as I wasnt sure if I could post the exact code into this form)
Unfortunately I needed to do this in the category_cloud.php file, if there is a way I can do it all using the function call that would be fine, but better yet is if it could be included in the next release.
Clint,
thanks for your feedback.
I’ll try to fix it in the next release :)
no prob! thanks for the plug :D
Hey, I was using your categories cloud plugin on my archive (which is currently down) and it kept showing up as a list instead of a cloud. I was wondering if there was a way to fix this?
Ali,
Can you give me some additional details?
Do you use a css file to style your (not yet) category cloud? what have you got in your before and after tags?
thanks
[…] PS2: si a alguien le interesa, el plugin se llama “Category Cloud”, es la version 1.6 y lo pueden descargar de aca. […]
It looks like this is breaking under WordPress 2.2. “Subcategories of” is no longer working on my site.
thanks tim, I’ll try to fix it in the next release!
Is there any widget support for Cloud plugin ?
It would make life more simpler
Please try to bring widget support.
Becomes hard to implement in wordpress 2.2
Thnaks
Gaurav,
I haven’t downloaded and installed wp 2.2 … I’ll have a look at it and see how hard is it to develop a widgeted version, but it will take time…
stay tuned ;)
[…] Category Cloud 1.6 - Wordpress Plugin | http://www.mapelli.info カテゴリークラウド作成プラグイン (tags: wordpress plugin tagcloud category) […]
[…] Category Cloud 1.6 - Wordpress Plugin | http://www.mapelli.info カテゴリークラウド作成プラグイン (tags: wordpress plugin tagcloud category) […]
Hi.
Love the plugin but I had some trouble with it on Dreamhost.
The plugin itself works wonderfully, but the options page borke when searching for updates because Dreamhost doesn’t allow the use of the php functions “fopen” or “file_get_contents” with a URL as the filename.
Dreamhost does however, allow the use of CURL.
So I added a check on line 340 to grab the page with CURL if the fopen fails!
Actually, now that I think about it, I changed the “fopen” to a “file_get_contents” because both “curl_exec” and “file_get_contents” return strings so it seemed simpler but that makes my version require PHP5.
Bah!
Back to praising yr plugin!
Bob, thanks for your hints.
I’ll add the curl support to the next version of category cloud.
thanks again :)
Hi.
The version 1.0 was widget supported, this version isn’t from of what I can see, is the function deleted although this is a higher version?
PLz do contact me if you know anything about this. Cheers!
//Aypeus (aypeus@aypeus.org)
aypeus,
sorry, but version 1.0 was not widgeted :)
why do you think it was?
it is great, thank you!
[…] еще ко всему прочему и Облако Категорий. Сенкс Максиму за сцылку =) Посмотреть можно на главной […]
[…] archives are also live once again, thanks to Super Archives and Category Cloud (which replaced the old Weighted Categories plugin that doesn’t work with the latest […]
Hi,
I have this error when installing:
Fatal error: Call to undefined function: get_categories() in /hsphere/local/home2/iqbalir/blog.iqbalir.com/wp-content/plugins/category_cloud.php on line 126
Could you please tell me why…??
Thx. :)
Sorry, wrong version. :(
Iqbal,
yes, my plugin requires wp version 2.1+ …
I’m sorry but the get_categories() function is not available in previous versions
[…] L’intallazione su wordpress e’ piuttosto banale: è sufficiente scaricare il pacchetto da qui , copiare il file category-cloud.php nella directory dei plugin di wordpress, attivarlo dal […]
Great plugin; exactly what I was looking for!
this plugin is awsum, u rock!
but its not valid xhtml :(
sry for tripplepost but i just wanned to tell ya that ive managed to modify it for my intentions and validate it. u should consider implementing validation in ur next version, thank u. :)
I was running this plugin for a while (with success), and now all of a sudden I got errors:
Warning: array_merge() [function.array-merge]: Argument #1 is not an array in [my wordpress dir]/wp-content/plugins/category_cloud.php on line 133
Warning: array_filter() [function.array-filter]: The first argument should be an array in [my wordpress dir]/wp-content/plugins/category_cloud.php on line 138
Warning: uasort() [function.uasort]: The argument should be an array in [my wordpress dir]/wp-content/plugins/category_cloud.php on line 253
Warning: Invalid argument supplied for foreach() in [my wordpress dir]/wp-content/plugins/category_cloud.php on line 171
Warning: Invalid argument supplied for foreach() in [my wordpress dir]/wp-content/plugins/category_cloud.php on line 194
I use wordpress v. 2.2. Anybody knows what to do?
temporary fix for my above problem:
It turns out plugin does not work with php5, where array_merge function has changed. on the lines 133, 138, 171 and 194 you have to cast $category variable to the array type.
But I am waiting for official solution ;)
I have just installed Category Cloud v.1.6 in my Wordpress 2.2.2 blog, but (upon updating options) I get the following errors:
checking updates...
Warning: fopen() [function.fopen]: URL file-access is disabled in the server configuration in /path/to/plugins/category_cloud.php on line 340
Warning: fopen(http://www.mapelli.info/lastversion.php?what=category_cloud) [function.fopen]: failed to open stream: no suitable wrapper could be found in /path/to/plugins/category_cloud.php on line 340
Unable to contact remote server while checking for updates
Warning: feof(): supplied argument is not a valid stream resource in /path/to/plugins/category_cloud.php on line 345
Warning: fgets(): supplied argument is not a valid stream resource in /path/to/plugins/category_cloud.php on line 346
The last two lines are repeated ad infinitum. I realise that this is simply because I have URL file access disabled (and so should everyone, I’d say) but I think Category Cloud should fail on version checking a bit more gracefully.
But, otherwise, I’d like to say that this is a great plugin, and thank you very much for writing and maintaining it. I really appreciate your work.
@Sam Wilson:
checking updates...Warning: fopen() [function.fopen]: URL file-access is disabled in the server configuration in /path/to/plugins/category_cloud.php on line 340
Try to ‘READ’ carefully: URL file-access is disabled in the server configuration
And now, get luck with your hosting company… :)
CCLOUD 1.6 bug @PHP5
Explanation
http://us3.php.net/manual/en/f.....-merge.php
Errors
Warning: array_merge() [function.array-merge]: Argument #1 is not an array in C:\AppServ\www\portfolio\wp-content\plugins\category_cloud.php on line 133
Warning: array_merge() [function.array-merge]: Argument #1 is not an array in C:\AppServ\www\portfolio\wp-content\plugins\category_cloud.php on line 133
Warning: array_filter() [function.array-filter]: The first argument should be an array in C:\AppServ\www\portfolio\wp-content\plugins\category_cloud.php on line 138
Warning: shuffle() expects parameter 1 to be array, null given in C:\AppServ\www\portfolio\wp-content\plugins\category_cloud.php on line 270
Warning: Invalid argument supplied for foreach() in C:\AppServ\www\portfolio\wp-content\plugins\category_cloud.php on line 171
Warning: Invalid argument supplied for foreach() in C:\AppServ\www\portfolio\wp-content\plugins\category_cloud.php on line 193
FIX
replace the line ~133:
$category = array_merge($category, get_categories($topass));with that:
$category = array_merge((array)$category, get_categories($topass));Best regards. :)
Option to display only subcategories of given categories
That’s not working for me, script only displays category 1 subcategories.
If I try “1, 6, 7″ only shows from first. But if I try “6, 7″ it shows nothing…
Any suggestions? :)
@albert
if it works, it’s a good fix ;)
I’ll add it to the next release, or I’ll try to rewrite the code to make it php5 compatible.
thanks for the contribution!
@sam
next version will have an option to disable the check for updates, and curl support, to fix this unelegant bug :)
thanks for reporting
@n37,
you can try this:
line 131 (or somewhere near it)
replace
foreach($parents as $parent) {
$topass['child_of'] = $parent;
$category = array_merge($category, get_categories($topass));
with
foreach($parents as $parent) {
$topass['child_of'] = trim($parent);
$category = array_merge($category, get_categories($topass));
please, let me know if this works
thanks
Thanks Francesco!
When I Insert
To display my cateogry cloud category display thats well fine.
But this adds 40 to 46 html validation errors to my each post ( singe page ).
I hope there may be some validation bug in your plugin.
I hope you’ll look at this since i love your plugin and my onlt concern is that it give too much of valiation errors.
Thanks !!! Gaurav Akrani
help please
i cant figure out where to put the code
do i need a php editor or is it on word press?
-newb
hambonie,
you have to add it to the code of your template, probably in the sidebar.php file…
Wordpress comes with a simple editor, you have to go to the admin section, than to presentation > theme editor and edit the file…
once you find the place where you want your category cloud to appear, you have to add the code provided.
hope that helps … but if you need further explanation feel free to write me! :)
nice!
it’s working now francesco…
thx 4 help! ^^
PS.: can u plz share the plugins u r using on the blog, in a post? it would be nice… or mail me plz… :D
Hi, your plugin is great but it seems I can’t include more than one subcategory in your option:
Include only subcategories of the listed categories, e.g.:1, 3, 42 show subcategories of categories with id 1, 3 and 42.
Do you know why? Thx a lot for your help! :)
@treiny:
watch at the reply to @n37 (me) on comment nº 50…
it will be fixed in next update, i think…
GL! ;D
I’m not sure it’s the same problem I have. Mine is that I can only see 1 subcategory and not all the ones I added in the option:
Include only subcategories of the listed categories, e.g.:1, 3, 42 show subcategories of categories with id 1, 3 and 42.
I put 2, 5, 8 and I only get subcategories of 2, not 5 either 8. If this is a bug, it’s a huge one. Maybe the author can help me out?
Thx ! :)
like i said, you can try this:
line 131 (or somewhere near it), replace:
foreach($parents as $parent) {$topass['child_of'] = $parent;
$category = array_merge($category, get_categories($topass));
with:
foreach($parents as $parent) {$topass['child_of'] = trim($parent);
$category = array_merge($category, get_categories($topass));
that should fix it…
if u r using PHP5, u’ll may fix too all the array_merge() functions like this:
before:
$category = array_merge($category, get_categories($topass));after:
$category = array_merge((array)$category, get_categories($topass));if u wont believe, it’s not my problem m8… i’ve fixed it… ;)
GL!
Treiny,
The bug seems to be the same found by n37, it can be corrected as exposed in comment 50 and 59 …
You’re right, it’s a huge bug … :( but it somehow was not found by my Q.A. team (that’s me and myself ;) ).
It will be fixed in the next release (I hope it will be out in late October…)
Thanks for reporting it.
Thank you so much n37, it works now :)
And thank you francesco for your great plugin, I will download the new version when it will be out ! :)
np m8… :)
@francesco:
if do you want some help on the new release but you haven’t got time, please send me an email and i try to help you update that great plugin… ;)
Best regards to all.
[…] Download the Category Cloud 1.6 plugin and unzip the files to a location you will remember. 2. Upload category-cloud.php to your Wordpress […]
You are god!
Hey,
The Category Cloud 1.6 isnt working on on blog. WP 2.1.3 with the i3theme (http://www.mangoorange.com/)
Please help. It didn’t work when I tried inserting the code in the Widgets. My whole sidebar is made of widgets. Its a hell lot of work to manually shift :(
it is great, thank you!
I really like the widget and have recently installed it, however, I am unable to modify any of the attributes of the widget. I am not sure if I can or not. The options interface seems to be ineffective. I am currently using WordPress 2.3
I just thought I’d mention it here, as an idea for the next release of Category Cloud: now that WP2.3 supports checking for plugin versions (if they’re hosted on wp-plugins.net) you could consider hosting the plugin there and removing the version checking.
Just an idea.
Thanks for all your work!
VjoSqy 3v3445vtt075nvn0g8d0nb
Thanks, this is really a useful plugin, i like it…
I was trying to use this plugin, im doing something wrong or what… :S
I put this code into a text widget
so it should work right? .. Damn..
Any advice will be great.
Hey,
is there a possibility to change the plugin so that I can using the cloud with tags? I am looking for a tagcloud colored like yours and working with the current Wordpress version. HELP ME!!
Robert
WARNING!: I don’t get CC to work on WP2.3.1
HELP!: Maybe I’m just dumb and need some assistance? Well, the header loads but the rest is a blank.
Any ideas?
[…] Now, I’m a man of my word… so I’m going to tell ya about a smart plugin called Category Cloud… […]
I love this plugin! It does exactly what I need it to do but it does not validate…Is there a temporary fix for this?
Thanks for this great plugin! :-)
Thanks, really one of the best WP plugins i have seen, implemented and works perfect…
hi there,
is it possible to exclude all users to edit the plugin? it feels crappy if somebody would change the look on your site without you knowing that:)
cheers and thanks for great plugin!
thanks
great plugin… nice can find this plugin..thanks
i notice there is no replies here but i wish i could find an answer to my question
does this plugin helps to make the parent categories only appear and if yes how can i do that
queeneve,
you’ve to exclude the subcategories by listing them in the “excluded categories ids” field, or force only the inclusion of the main categories by adding them in the “included categories id”
hth
francesco
Exactly what I needed — thanks.
Thx for this great plugin!
[…] Category Cloud » to create cloud from your categories […]
[…] tips & www social trends « Category Cloud 1.6 Apr 17, 2007 at 10:53 pm about blogging, tips (No Ratings Yet) Loading […]
[…] Nella sidebar grande (quella a destra) le categorie hanno una forma particolare, sono messe in tag cloud in modo da dare più rilievo alle categorie più ricche del blog. Per fare questo mi sono servito di un altro plugin italiano: Category Cloud. […]
I’ve installed v. 1.6 of the plug-in and am on wp 2.3.2. I am trying to use it in my sidebar by putting the code in a php code widget. I would like to show only subcategories of category 117, which I put in the options. I did not specify any exclude, include or max categories. I do not have anything in the before or after code boxes. When I view it, I *very* briefly see the categories as I would hope to and then immediately it all changes to show “undefined” for every category. Very strange.
Ha, what a perfect plug-in! Set it up in 30 seconds and it does everything I need - well done!
I am not sure if someone has already reported this or not but there is a small glitch I found in the plugin version 1.6.
on line 218 there should be an space before style otherwise the plugin would work just fine but it won’t produce a valid markup. Adding a simple space solved this for me. I don’t know if we can write code here or not but i am trying below:
original:
$toprint.="style=\"font-size: $size$ccloud_unit; $color\">$cat->cat_name$count“;
Fixed:
$toprint.=” style=\”font-size: $size$ccloud_unit; $color\”>$cat->cat_name$count“;
[…] dúvidas Out 21 Category Cloud Domingo, 21-10-2007 # 11:22 Plugins, Tutoriais 314 palavras Plugin que mostra as categorias dos posts em uma nuvem de tags colorida. Compatível com Wordpress 2.1 à 2.5. Para outras versões do wordpress, verifique a compatibilidade ou a disponibilidade de outra versão do plugin no site do autor. Página do plugin mapelli.info […]
As James said above, perfect plugin! Very easy install and I like the range of config options. Thanks for releasing this.
Just Perfect ;)
Hi, there is a bug in your HTML output.
1. Code is invalid when using list elements because you can’t place a LI in a SPAN, and you can’t place a DIV in a UL.
2. It’s impossible to enter correct font-sizes when working with the em unit, due to both the link and its surrounding SPAN getting the font size. Since EM is relative to its container, a font size of 11px effectively turns into 12.1px.
I will edit the plugin code to remove the invalid code, but that of course will break the next time I need to update it. Could you perhaps make the SPANs an option that can be toggled on and off, and move the DIV somewhere else for your next update?
Nice plugin :)
[…] Category Cloud […]
[…] Category cloud needing to be limited to 10 categories (sorted thanks to this widget) […]
I’m having a problem with the “Subcategories of” settings. I have a parent category, 23, with approximately 30 child categories. When I enter the number 23 into “Subcategories of”, none of the child category names appear, even those with posts. When I leave “Subcategories of” blank, all categories appear properly.
Any ideas?
I’m using Wordpress 2.7 and v1.6 of your plugin.
Hi Francesco, I am running your plugin with Wordpress 2.7.1.
I have problem every time I modify a parameter and then i click on “update options” button.
The browser (Firefox, IE, Opera, Safari) freezes and I have to kill it down.
The parameters are updated but I need to open a new browser session, login again in my WP admin panel and so on.
Is there a way to fix this issue?
Thank you! :)
Ops, I forgot to say I am using version 1.6 of your plugin.
[…] http://www.mapelli.info/web20/category-cloud-16 […]
Nice, thanks for sharing :)
[…] Category Cloud […]
[…] Category Cloud […]
Is it possible to only display the sub categories of a categories/archive page?
Very nice plugin! I very much like the setting options!
One question from me:
I want to align the cloud in the center, so that it will have a more “cloud-like” appearance.
But I can’t figure out where to put the style sheet info for a customisation.
And do I have to call it from somewhere?
Thanx 4 any help!
Okay, here is the answer to my own question from above:
it can be inserted into same widget as the PHP-if check.
Here is mine:
#category_cloud {
text-align: center;
line-height: auto;
}
[…] site do autor você encontra outras opções de configuração. 05. Se desejar ajustar valores no css use: […]
I am not sure how this or any cloud effects on google. I have issuded some suggestions from google webmaster tool about duplicated meta tags, and all links that have duplicated tags was from cloud. Probably because more words from cloud lead to same page, and google somehow think it is different page with same meta tags.
The question is, are these clouds good or bad from google’s point of view
Any experience with this, If anybody understand what i was talking about :) .
Sorry for bad english
Leave a reply
Comments and trackbacks are dofollowed. Be sure to read my comment policy once in a lifetime before posting