MediaWiki:WW

 console.log("Now loading content of Writer's Workshop board..."); $.ajax({	url: '/wiki/Board:Writer%27s_Workshop',	type: 'GET',	success: function (data) {		console.log("Content loaded!");		var content = $(data).find('ul.ThreadList').html;		var contentlength = $(content).length + 1;		contentlength = contentlength / 2;		var threadnum = Math.floor((Math.random*contentlength )+1);		$('div.redirect').append($(content));		var threads = [];		$('div.redirect li').each(function(index) { if (typeof $(this).attr('data-id') !== 'undefined') { console.log($(this).attr('data-id')); threads[threads.length] = $(this).attr('data-id'); }		});		var thread = threads[Math.floor(Math.random*threads.length)];		console.log("Selected: " + thread);		window.location.replace("/wiki/Thread:" + thread);	},	error: function ( jqXHR, textStatus, errorThrown ) {		$('div#mw-content-text').append(" There was an error fetching Writer's Workshop threads, please show an admin this page for assistance. " + textStatus + " - " + errorThrown + " ");	} });