Showing posts with label Clouds. Show all posts
Showing posts with label Clouds. Show all posts

Oct 31, 2009

Tag Cloud - How to...

This post will explain how to implement a tag cloud onto your website:
For our group project, we planned to implement a tag cloud on website. We decided for the API of http://www.semager.de/.
At first, we used the proxy to create a request on their server:
$uri = 'www.semager.de/api/tagcloud.php?url=http://people.emich.edu/jabbouda/project/3/index.htm 


The result confused us. The semager-server has not processed the content, displayed on our website. Well, sure. It just processes the information that it founds on the website (without any content which was generated from our scripts).
The problem we had to solve was to save the generated data in a file, but how?
The answer is PHP:
$file=fopen("ebay.xml","w+");
// $file is the file handler. ebay.xml the filename,
// "w+" describes that we want to read and write the
// file, and that it deletes the content of an
// existing file or creates a new file, in the case
// there not such a file

fwrite($file,$xml);
// writes the content fo $xml into the file.
// $xml is the result that we got from the ebay server

fclose($file);
// closes the file after working on that
//

We changed our ebay-proxy file and inserted the lines above. The result is that the xml data that we receive is saved in the file: ebay.xml, on the server.
You have to know that the people.emich.edu does not allow creating / saving by PHP commands. This is the reason why we moved our project to:
http://www.highspeed-karlsruhe.de/cms/tmp/install_4a7adbd79d4d2/is449/

We changed the link in proxy file for the tag cloud and now we receive ready converted html data. This is displayed in the div tag.
Usually you must be able to get this running on your local XAMPP server.

Sep 23, 2009

Web 2.0 – Tag Clouds

After talking about Web 2.0 technologies I just looked “Web 2.0” up and realized that there is a special form of user interaction that just strikes my eyes: Tag Clouds.

Tag Clouds allows to represent words that users had tagged on posts in a special way:







Often used words will be highlighted by a bigger and brighter color, automatically.

Administrator or publishers can not influence a tag cloud that represents user posts and their tags. The Tag Clouds allows new user to get an idea of the important topics of a website or a blog.

Although this is a very interesting technique of categorizing the content of a website, it is necessary that the used tags are relevant to its specific post. Not tagging or wrong tags would cause a not representative tag cloud. Using some conventions, like the use of only lowercase and only singular, and not that concrete words decreases duplicates and almost similar words in your Tag Cloud. This means that your Tag Cloud will be more meaningful.


Sources:

http://en.wikipedia.org/wiki/Tag_cloud

http://www.smashingmagazine.com/2007/11/07/tag-clouds-gallery-examples-and-good-practices/