-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
61 lines (47 loc) · 1.88 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
Taggify jQuery Plugin
=====================
Use Taggify to tag items and generate a tag cloud without need for any server side code or database.
### Demo ###
http://alexwelch.com/taggify
### Features ###
### Usage ###
1. Get JQuery. In these examples, we use Google's AJAX Libraries API.
- http://code.google.com/apis/ajaxlibs/
- http://jquery.com/
2. include jQuery and jquery.taggify.js files in your template's <head>.
<script language="javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.1/jquery.min.js" type="text/javascript"></script>
<script language="javascript" src="jquery.taggify.js" type="text/javascript"></script>
3. Also in <head>, Invoke the methods to find tags and generate the cloud
<script type='text/javascript'>
$(document).ready(function(){
$('div#tags_go_here').taggify();
});
</script>
4. In <body> make sure to create an element to place the tag-cloud into, in this case you would call it <div id="tags_go_here"></div>
5. Also in <body> create a list of taggable items for example a serious of divs or lis with that may be uniquely selected, the default assumption is a series of items within an element with the id "taggable_items" containing multiple elements with the class "taggable_item" containing a div with a class of "tags" containing an unordered list of tags
- For example:
<div id="taggable_items">
<div class='taggable_item'>
<h3>Taggable Item 1</h3>
<div class='tags'>
<ul>
<li>Ruby on Rails</li>
<li>Cat</li>
<li>Dog</li>
</ul>
</div>
</div>
<div class='taggable_item'>
<h3>Taggable Item 2</h3>
<div class='tags'>
<ul>
<li>Another Tag</li>
<li>Safer Tag</li>
</ul>
</div>
</div>
</div> <!-- end #taggable_items -->
6. Style it however you like.
### Customization ###
...
Visit http://alexwelch.com/taggify for more information