PHP Classes

cal_TagCloud: Display a tag cloud from an array of tags

Recommend this page to a friend!
  Info   View files View files (3)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStarStar 63%Total: 943 This week: 1All time: 3,807 This week: 560Up
Version License PHP version Categories
cal_tagcloud 1.2GNU General Publi...5.0PHP 5, Content management
Description 

Author

This class can be used to generate a tag cloud from an array of tags.

It takes an array with a list of tags and generate the cloud considering the number of times each tag appears in the list.

The class outputs a piece of HTML with links with the tag names pointing to pages with more detail about each tag.

The presentation of each tag is defined using CSS styles. The name of the CSS style of a tag is defined by a configurable prefix followed by the score of the tag.

The maximum number of tags to show in the cloud and the format of the tag link URL are also configurable details.

Picture of Cal Evans
Name: Cal Evans <contact>
Classes: 1 package by
Country: United States United States
Age: ???
All time rank: 2439334 in United States United States
Week rank: 416 Up46 in United States United States Up

Details

Cal Evans <cal@calevans.com> My Homepage: http://www.calevans.com Project Homepage: http://www.calevans.com/view.php/page/tagcloud (c) 2006 Cal Evans, All Rights Reserved Licensed under the GPL 2.0 --- 1: Create a directory cal somewhere in your include_path. 2: Place TagCloud.php in it. 3: In your code use: require 'cal/TagCloud.php'; $cloudMaker = new cal_TagCloud($yourArrayOfTags); // Set options here. $cloudMaker->buildCloud(); echo $cloudMaker->cloudOutput; In the above example, $yourArrayOfTags is a single dimensional array of tags. The more a tag is in the array, the higher it's weight and score. See tagCloydTest.php for a working example. You can see a working example on the project homage: http://www.calevans.com/tagCloud/ Email me if you have questions. =C=

  Files folder image Files  
File Role Description
Accessible without login Plain text file README.TXT Doc. Basic instructions
Plain text file TagCloud.php Class The main class
Plain text file testTagCloud.php Example Self contained test file

 Version Control Unique User Downloads Download Rankings  
 0%
Total:943
This week:1
All time:3,807
This week:560Up
 User Ratings  
 
 All time
Utility:83%StarStarStarStarStar
Consistency:83%StarStarStarStarStar
Documentation:66%StarStarStarStar
Examples:66%StarStarStarStar
Tests:-
Videos:-
Overall:63%StarStarStarStar
Rank:819