Generating Tags

User avatar
agibsonsw
SilverLounger
Posts: 2403
Joined: 05 Feb 2010, 22:21
Location: London ENGLAND

Generating Tags

Post by agibsonsw »

Hello.
On many sites they have a panel of 'Tags' or keywords which are links to a search on the keyword. Sometimes they are followed by numbers (24) and
sometimes they are in different sized text. Amazon even allows you to create your own tags.
I have asked concerning these before and it appears they are plain HTML links or they use some Javascript. But are they auto-generated somehow? Or does the
page designer update them manually?
Thanks, Andy.
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.

User avatar
HansV
Administrator
Posts: 78474
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: Generating Tags

Post by HansV »

See Tag cloud on Wikipedia.
Best wishes,
Hans

User avatar
agibsonsw
SilverLounger
Posts: 2403
Joined: 05 Feb 2010, 22:21
Location: London ENGLAND

Re: Generating Tags

Post by agibsonsw »

Thank you. Wikipedia didn't explain how to create them but just knowing the proper term 'tag cloud' helped me to find more information.

I'm not saying they are great.. in fact a quote from the original creater on the Wikipedia page is 'sorry about the tag clouds' lol. Andy.
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.

User avatar
HansV
Administrator
Posts: 78474
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: Generating Tags

Post by HansV »

Near the end of the article, there is a link to Wordle - Beautiful Word Clouds.
Best wishes,
Hans

User avatar
agibsonsw
SilverLounger
Posts: 2403
Joined: 05 Feb 2010, 22:21
Location: London ENGLAND

Re: Generating Tags

Post by agibsonsw »

I saw that link and looked at it. There are tools that can create tag clouds but I was more interested in how it was achieved.

I found a site http://www.roscripts.com/Create_tag_cloud-71.html with a PHP function to generate a tag cloud, based on an array
of text, value pairs. I assume that sites would also store search terms and then feed them into such a function to automatically generate
the tag cloud.

It seems that 'cloud' is the new word of this computer age :fanfare: Andy.
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.

User avatar
HansV
Administrator
Posts: 78474
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: Generating Tags

Post by HansV »

:cloud9:
Best wishes,
Hans

User avatar
Jezza
5StarLounger
Posts: 847
Joined: 24 Jan 2010, 06:35
Location: A Magic Forest in Deepest, Darkest, Kent

Re: Generating Tags

Post by Jezza »

Andy
There are other methods of doing this, one way I was playing with was storing the tag words in the form of eXtensible Markup Language (XML) and transforming it using XSLT. The XSLT can count the number of times a word appears and then using that calculated value to be a new parameter for a font size.

I had a very rough working model that utilised CSS
Jerry
I’ll be more enthusiastic about encouraging thinking outside the box when there’s evidence of any thinking going on inside it

User avatar
agibsonsw
SilverLounger
Posts: 2403
Joined: 05 Feb 2010, 22:21
Location: London ENGLAND

Re: Generating Tags

Post by agibsonsw »

I assume the raw data format would determine the approach. It could be a single column of repeating tags, two columns containing
the tags and their count, or just a large text file.
A large text file would prove quite complicated I suppose because you would have to parse it to find repeated phrases rather than just single words?
Wouldn't that then be similar to what an indexer application (for a book) does? Andy.
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.

jolas
3StarLounger
Posts: 204
Joined: 02 Feb 2010, 23:58

Re: Generating Tags

Post by jolas »

Here is a link that can help generate it for you with FAQ.