summaryrefslogtreecommitdiff
path: root/src/site-media/js/jquery.meetingtools.js
blob: 5bed8f36b9675c8f37ed94e7b073a233dd8b1a29 (plain)
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
/*
 *
 *
 *
 */

jQuery.fn.meetingtools = function(options) {
	
	this.each(function() {
		var tags = options.tags;
		var url = options.url;
		if (!url) {
			url = 'http://localhost:8000';
		}
		var url = url+'/room/+'+tags+'.json'
		var div = $(this)
		$.getJSON(url,function(data) {
			div.append("<ul style=\"list-style: none;\">")
			$.each(data,function(room) {
				div.append("<li style=\"display: list-item; list-style: none; padding: 2px; 5px;\" class=\"ui-helper-reset ui-widget ui-state-highlight ui-corner-all\">");
				div.append(room['url']);
				div.append("</li>");
			});
			div.append("</ul>")
		});
		
	});
}