(function() {
var ds_namespace = '__dsns_', ds_plugin_name = 'WITI_WidgetsV1';
window[ds_plugin_name] = function() {
	var Keywords = 'Anna Nicole Smith,Arlen Specter,Barack Obama,Baseball,Basketball,Beaver Dam,Belgium,Beverly Taylor,Bob Moore,Bowling,Boxing,Brad Hicks,Brad Miller,Brookfield,Brown Deer,Brownsville,Bryan Polcyn,Burlington,Burnett,Butler,Caledonia,Cathy Orosz,Cedarburg,Chris Smith,Chrystina Head,Cudahy,Cycling,David Archuleta,David Clarke,Delafield,Delavan,Eagle,East Troy,Ed Flynn,Elkhorn,Elm Grove,Football,Fort Atkinson,Franklin,Germantown,Golf,Grafton,Greendale,Gus Gnorski,Gwen Moore,Hales Corners,Harry Reid,Hartford,Hartland,Henry Rosoff,Herb Kohl,Hillary Clinton,Hockey,Jackson,Jefferson,Jen Lada,Jeremy Ross,Jim Doyle,Jim Sensenbrenner,Joe Biden,John Boehner,John Chisholm,John Dickert,John Kerry,John McCain,John Russell,Johnny Depp,Johnson Creek,Juneau,Justin Williams,Katrina Cravy,Kenosha,Kewaskum,Kim Murphy,Kohler,Lake Geneva,Ludacris,Max Baucus,Mayville,Menomonee Falls,Mequon,Michael Jackson,Mike Lowe,Miley Cyrus,Milwaukee,Mitch McConnell,Mitt Romney,Mukwonago,Muskego,Myra Sanchick,Nancy Pelosi,New Berlin,Newburg,Nicole Koglin,Oak Creek,Oconomowoc,Oprah Winfrey,Paul Ryan,Paula Abdul,Pewaukee,Pleasant Prairie,Plymouth,Port Washington,Racine,Random Lake,Randy Jackson,Richfield,Rob Haswell,Rugby,Russ Feingold,Sarah Palin,Sarah Platt,Saukville,Scott Walker,Shaquille O\'Neal,Sharon,Sheboygan,Simon Cowell,Skiing,Soccer,Softball,South Milwaukee,Sturtevant,Sullivan,Sussex,Tami Hughes,Ted Perry,Tennis,Tiger Woods,Tim Van Vooren,Tom Barrett,Tom Pipines,Union Grove,Usher,Vince Condella,Volleyball,Walworth,Waterford,Watertown,Waukesha,Waupun,Wauwatosa,West Allis,West Bend,Whitefish Bay,Whitewater,Wrestling,'.split(','); var qsHTML = '<div class="dsnsqs">\n  <div class="title">\n    <div class="text">Advanced Search</div>\n    <div class="close">&times;</div><i></i>\n  </div>\n  <form action="http://search.fox6now.com">\n    <input type="hidden" name="ct" value="r" />\n    <label for="qscat_\{id\}">Category</label><select id="qscat_\{id\}" rel="20198">\n      <option value="">( any category )</option>\n      <!--<option value="89000013">Local &amp; Regional</option>\n      <option value="20249789">YouNews</option>\n      <option value="89000010">National &amp; World</option>\n      <option value="20249325">Entertainment</option>\n      <option value="89000038">Business</option>\n      <option value="20249732">Sports</option>\n      <option value="89000015">Offbeat</option>\n      <option value="89000026">Technology</option>\n      <option value="90000049">Health</option>\n      <option value="89000017">Consumer</option>\n      <option value="20249757">Weather</option>\n      <option value="20249745">Traffic</option>\n      <option value="90000010">Economy</option>\n      <option value="20249604">Blogs</option>-->\n    </select><i></i>\n    <label for="qsfeat_\{id\}">When</label><select id="qsdate_\{id\}" rel="r.STRDAT">\n      <option value="">( anytime )</option>\n      <option value="0">Today</option>\n      <option value="7">Past 7 Days</option>\n      <option value="30">Past 30 Days</option>\n      <option value="365">Past 12 Months</option>\n    </select><i></i>\n    <label for="qscity_\{id\}">City</label><select id="qscity_\{id\}" rel="361">\n      <option value="">( any city )</option>\n      <!--<option value="106764" rel="639">Seattle</option>\n      <option value="99958" rel="653">Olympia</option>\n      <option value="110075" rel="202">Tacoma</option>\n      <option value="83672" rel="650">Everett</option>\n      <option value="107900" rel="650">Snohomish</option>\n      <option value="74149" rel="639">Bellevue</option>\n      <option value="91173" rel="639">Kirkland</option>\n      <option value="103621" rel="639">Redmond</option>-->\n    </select><i></i>\n    <label for="qscnty_\{id\}">County</label><select id="qscnty_\{id\}" rel="6">\n      <option value="">( any county )</option>\n      <!--<option value="639">King</option>\n      <option value="202">Pierce</option>\n      <option value="653">Thurston</option>\n      <option value="650">Snohomish</option>\n      <option value="640">Kitsap</option>\n      <option value="656">Whatcom</option>\n      <option value="648">Skagit</option>-->\n    </select><i></i>\n    <label for="qstext">Keywords</label><input class="qstext" name="q" /><i></i>\n    <input type="submit" class="normalbutton" value="Search" /><i></i>\n  </form>\n</div>'; var lfHTML = '<div id="dsnslocalnews"><!--\n\t<div class="title"><p>Your Neighborhood</p> <a class="pickcommunity" href="#pickcommunity">Change <span>&raquo;</span></a></div>\n\t<div class="city"><a href="http://community_link/">community_name News</a></div>\n\t<ul>\n\t\t<li class="first"><a href="http://first_link/"><div class="localimg"><img src="http://the_image/" alt="first_title"/></div>first_title</a><i class="clear"></i></li>\n\t\t<li class="second"><a href="http://second_link/">second_title</a></li>\n\t\t<li class="third"><a href="http://third_link/">third_title</a></li>\n\t\t<li class="fourth"><a href="http://fourth_link/">fourth_title</a></li>\n\t\t<li class="fifth"><a href="http://fifth_link/">fifth_title</a></li>\n</ul>-->\n</div>\n\n<div id="dsnslocallinks" class="bottom_links">\n\t<a class="morenews" href="http://community_link/">More News</a>\n\t<div class="sep"></div>\n</div>\n<div id="dsnsOverlay">&nbsp;</div>\n<div id="dsnsLfPopup">\n\t\t<div class="topHead">\n\t\t\t\t<h1>Choose your neighborhood</h1>\n\t\t\t\t<div class="subHead">Tell us where you live and get your community headlines along with your local, breaking news.</div>\n\t\t\t\t<div class="closeButton"><a href="#close">close window</a></div>\n\t\t</div>\n\t\t<div class="mainHoodContent">\n\t\t\t<div class="introText">Choose the neighborhood closest to you. If you don\'t see your neighborhood, <a href="http://www.fox6now.com/about/contactus/">let us know</a>! We\'ll be adding more neighborhoods soon!</div>\n\n\t\t\t\t<div class="box">\n\t\t\t\t\t<h3>Milwaukee Co.</h3>\n\t\t\t\t\t<ul class="column">\n\t\t\t\t\t\t<li><a href="#northshore">Bayside</a></li>\n\t\t\t\t\t\t<li><a href="#bayview">Bay View</a></li>\n\t\t\t\t\t\t<li><a href="#northwest">Brown Deer</a></li>\n\t\t\t\t\t\t<li><a href="#southshore">Cudahy</a></li>\n\t\t\t\t\t\t<li><a href="#eastside">Downtown</a></li>\n\t\t\t\t\t\t<li><a href="#eastside">East Side</a></li>\n\t\t\t\t\t\t<li><a href="#northshore">Fox Point</a></li>\n\t\t\t\t\t\t<li><a href="#southwest">Franklin</a></li>\n\t\t\t\t\t\t<li><a href="#northshore">Glendale</a></li>\n\t\t\t\t\t\t<li><a href="#southwest">Greendale</a></li>\n\t\t\t\t\t\t<li><a href="#southwest">Greenfield</a></li>\n\t\t\t\t\t\t<li><a href="#southwest">Hales Corners</a></li>\n\t\t\t\t\t\t<li><a href="#northwest">Midtown</a></li>\n\t\t\t\t\t\t<li><a href="#northshore">North Shore</a></li>\n\t\t\t\t\t\t<li><a href="#northwest">Northwest</a></li>\n\t\t\t\t\t\t<li><a href="#southshore">Oak Creek</a></li>\n\t\t\t\t\t\t<li><a href="#northshore">River Hills</a></li>\n\t\t\t\t\t\t<li><a href="#eastside">Riverwest</a></li>\n\t\t\t\t\t\t<li><a href="#northshore">Shorewood</a></li>\n\t\t\t\t\t\t<li><a href="#southshore">South Milwaukee</a></li>\n\t\t\t\t\t\t<li><a href="#southshore">South Shore</a></li>\n\t\t\t\t\t\t<li><a href="#southwest">Southwest</a></li>\n\t\t\t\t\t\t<li><a href="#southshore">St. Francis</a></li>\n\t\t\t\t\t\t<li><a href="#thirdward">Third Ward</a></li>\n\t\t\t\t\t\t<li><a href="#wauwatosa">Wauwatosa</a></li>\n\t\t\t\t\t\t<li><a href="#westallis">West Allis</a></li>\n\t\t\t\t\t\t<li><a href="#westallis">West Milwaukee</a></li>\n\t\t\t\t\t\t<li><a href="#northshore">Whitefish Bay </a></li>\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\t\t\t\t\n\t\t\t\t<div class="box">\n\t\t\t\t\t<h3>North</h3>\n\t\t\t\t\t<ul class="column">\n\t\t\t\t\t\t<li><a href="#dodge">Beaver Dam</a></li>\n\t\t\t\t\t\t<li><a href="#cedarburg">Cedarburg</a></li>\n\t\t\t\t\t\t<li><a href="#dodge">Dodge Co.</a></li>\n\t\t\t\t\t\t<li><a href="#grafton">Grafton</a></li>\n\t\t\t\t\t\t<li><a href="#menomoneefalls">Germantown</a></li>\n\t\t\t\t\t\t<li><a href="#hartford">Hartford</a></li>\n\t\t\t\t\t\t<li><a href="#hartford">Jackson</a></li>\n\t\t\t\t\t\t<li><a href="#mequon">Mequon</a></li>\n\t\t\t\t\t\t<li><a href="#grafton">Port Washington</a></li>\n\t\t\t\t\t\t<li><a href="#grafton">Saukville</a></li>\n\t\t\t\t\t\t<li><a href="#hartford">Slinger</a></li>\n\t\t\t\t\t\t<li><a href="#mequon">Thiensville</a></li>\n\t\t\t\t\t\t<li><a href="#dodge">Watertown</a></li>\n\t\t\t\t\t\t<li><a href="#dodge">Waupun</a></li>\n\t\t\t\t\t\t<li><a href="#hartford">West Bend</a></li>\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\t\t\t\t\t \n\t\t\t\t<div class="box">\n\t\t\t\t\t<h3>West</h3>\n\t\t\t\t\t<ul class="column">\n\t\t\t\t\t\t<li><a href="#brookfield">Brookfield</a></li>\n\t\t\t\t\t\t<li><a href="#lakecountry">Delafield</a></li>\n\t\t\t\t\t\t<li><a href="#brookfield">Elm Grove</a></li>\n\t\t\t\t\t\t<li><a href="#lakecountry">Hartland</a></li>\n\t\t\t\t\t\t<li><a href="#lakecountry">Lake Country</a></li>\n\t\t\t\t\t\t<li><a href="#menomoneefalls">Menomonee Falls</a></li>\n\t\t\t\t\t\t<li><a href="#southwest">Muskego</a></li>\n\t\t\t\t\t\t<li><a href="#westallis">New Berlin</a></li>\n\t\t\t\t\t\t<li><a href="#lakecountry">Oconomowoc</a></li>\n\t\t\t\t\t\t<li><a href="#lakecountry">Okauchee</a></li>\n\t\t\t\t\t\t<li><a href="#lakecountry">Pewaukee</a></li>\n\t\t\t\t\t\t<li><a href="#waukesha">Waukesha</a></li>\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\t\t\t\t\t \n\t\t\t\t<div class="box">\n\t\t\t\t\t<h3>South</h3>\n\t\t\t\t\t<ul class="column">\n\t\t\t\t\t\t<li><a href="#kenosha">Kenosha Co.</a></li>\n\t\t\t\t\t\t<li><a href="#racine">Racine Co.</a></li>\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class="popupBottom">\n\t\t\t<div class="logo" alt="Fox6Now">Fox6Now.com</div>\n\t\t</div>\n</div>'; var lbHTML = '<div class="sponsor">\n\t<a class="thumb" href="the_link"><img src="the_img" /></a>\t\n\t<span class="title">Community\tSponsor</span><br />\n\t<a class="name" href="the_link">the_title</a>\n\t<i class="clear"></i>\n</div>'; var dlHTML = '';
	var plugin_name = ds_plugin_name;
	var Load = function() {
		if(typeof window[ds_namespace] != "object")
			window[ds_namespace] = {};
		if(typeof window[ds_namespace].OnInit != "undefined") {
			if(window[ds_namespace].Initialized) {
				window[ds_plugin_name].Init(window[ds_namespace]);
				if(window[ds_namespace].IsReady)
					window[ds_plugin_name].Ready(window[ds_namespace]);
				else
					window[ds_namespace].OnReady.push(window[ds_plugin_name].Ready);
			}
			else {
				window[ds_namespace].OnInit.push(window[ds_plugin_name].Init);
			}
			return;
		}
		
		if(typeof window[ds_namespace].$ == "function") {
			window[ds_plugin_name].$ = window[ds_namespace].$;
			window[ds_plugin_name].Init();
			return;
		}
		if(typeof window[ds_plugin_name].$ == "function") {
			window[ds_plugin_name].Init();
			return;
		}
 
		if(typeof jQuery == "function" && (
			jQuery.fn.jquery == '1.3' || 
			jQuery.fn.jquery == '1.3.1' || 
			jQuery.fn.jquery == '1.3.2' || 
			jQuery.fn.jquery == '1.4' || 
			jQuery.fn.jquery == '1.4.1' || 
			jQuery.fn.jquery == '1.4.2')) {
			window[ds_plugin_name].$ = jQuery;
			window[ds_plugin_name].Init();
			return;
		}
		
		var el = document.createElement('SCRIPT');
		el.setAttribute('language', 'JavaScript');
		el.setAttribute('src', 'http://cdn.secondspace.com/news/jquery.js');
		document.getElementsByTagName('head')[0].appendChild(el);
		WaitForInit(1000);
	}
		
	var WaitForInit = function(max) {
		if(typeof window[ds_namespace].$ != "function") {
			if (max > 0)
				setTimeout(function() { window[ds_plugin_name].WaitForInit(max - 1); }, 10);
			return;
		}
		window[ds_plugin_name].Init();
	}
	var WaitForReady = function(max) {
		if(!max) max = 100;
		if(typeof window[ds_plugin_name].FullyInitialized != 'bool') {
			if (max > 0)
				setTimeout(function() { window[ds_plugin_name].WaitForReady(max - 1); }, 10);
			return;
		}
		window[ds_plugin_name].Ready();
	}
	var WaitForBody = function(max) {
		if(!max) max = 100;
		try {
			document.body.className += ' dsnsjs';
		} catch (e) {
			if (max > 0)
				setTimeout(function() { window[ds_plugin_name].WaitForBody(max - 1); }, 10);
		}
	}
	
	var SetCookie = function(name, value, expires, domain, path) {
		if(!expires) expires = 'Wed, 1 Jan 2020 00:00:00 UTC';
		if(!path) path = '/';
		if(!domain && location.host.indexOf('.') != -1) { // default to topmost domain
			var a = location.host.split('.');
			domain = '.' + a[a.length-2] + '.'+ a[a.length-1];
		}
		document.cookie = name+'='+value+'; expires='+expires+'; domain='+domain+'; path='+path;
	}
	
	var GetCookie = function(name) { 
		var nameEQ = name + '=';
		var ca = document.cookie.split(';');
		for(var i=0;i < ca.length;i++) {
			var c = ca[i];
			while (c.charAt(0)==' ') c = c.substring(1,c.length);
			if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
		}
		return null;
	}
	
	var Init = function(init_host) {
		if(window[ds_plugin_name].Initialized) return;
		window[ds_plugin_name].Initialized = true;
		var $ = window[ds_plugin_name].$;
		if(typeof $ == 'undefined')
		{
			if(init_host && typeof init_host.$ == 'function') // we're a plugin
				$ = window[ds_plugin_name].$ = init_host.$;
			else 
				$ = window[ds_namespace].$;
		}
		if(typeof $ == 'undefined')
			return;
		
		$.ajaxSetup({ cache: true });
		var IE = $.browser.msie;
		var IE6 = IE && /MSIE 6/.test(navigator.userAgent);
		var IE8 = IE && /MSIE 8/.test(navigator.userAgent);
		
		function Bind(sel, ev, func) {$(sel).live(ev, func);}
		function FullQuery(q) {var r = {};if(!q) q = CurrentSearch();if(!q) return new Array(); q = q.replace(/^\?/,'').replace(/\&$/,'');$.each(q.split('&'), function(){r[this.split('=')[0]] = this.split('=')[1];});return r;};
		function CurrentSearch() {var s = GetMetaData($('.searchquery'), location.search);if(!s || s == undefined)return false;return s;}
		function GetMetaData(el, fallback) {el = $(el); if (typeof fallback == 'undefined') fallback = false; if (el.length == 0) return fallback; var h = $.trim(el.html());if (h.length > 6) {if (h.slice(0, 5).toLowerCase() == '<pre>') h = h.slice(5); if (h.slice(0, 4) == '<!--') h = h.slice(4);if (h.slice(-6).toLowerCase() == '</pre>') h = h.slice(0, -6); if (h.slice(-3) == '-->') h = h.slice(0, -3);}return $.trim(h);}
		
		var Autocomplete = function(input) {
var host = $(input);
var cache = new Array();
var pending,popup,seeAllLink,list;
var options = {extraleft:0, extrawidth:0, maxheight:175, extratop:0, altpos:false, host:'BODY', match:'startword'}; // match:all, start, startword

function Render(data, q, c) {
	if(typeof data == 'undefined' || typeof data.suggest == 'undefined')
		return;
	
	list.empty();
	seeAllLink.css({ display: 'none' }).unbind();
	var html1 = new Array();
	var html2 = new Array();
	var html3 = new Array();
	var all = new RegExp(query, 'i');
	var start = new RegExp('^'+query, 'i');
	var startword = new RegExp(' '+query, 'i');
	var count = 0;
	var truncated = false;
	for(var i=0;i<data.suggest.length;i++) {
		var matched = false;
		var s = data.suggest[i].replace( all, function(q) { matched = true; return '<span class="match">' + q + '</span>' });
		if (matched) {
			// test if the cached data is valid
			var l = data.suggest[i].toLowerCase();
			if (typeof q != 'undefined' && typeof c != 'undefined' && l.indexOf(c) != l.indexOf(q))
				return false;
			if(start.test(l))
					html1.push('<li>' + s + '</li>');
			else if(startword.test(l) && options.match == 'startword')
					html2.push('<li>' + s + '</li>');
			else if(options.match == 'all')
					html3.push('<li>' + s + '</li>');
			else
				continue;
			count++;
			if (count > 100 && !seeAll) {
				truncated = true;
				break;
			}
		}			
	}
	if (html1.length + html2.length + html3.length == 0) {
		popup.css({ display: 'none' });
		return true;
	}
	list.append(html1.join('') + html2.join('') + html3.join(''));
	if (truncated) seeAllLink.css({ display: 'inline' }).click(function() { Complete(true); host.focus(); return false; });
	
	var o = host.offset();
	if(options.altpos == '1' || options.altpos == 'true')
		o = host.position();
	else if('' == 'position' && window.location.host.indexOf('search') == 0)
		o = host.position();
	else if('' == 'position' && window.location.host.indexOf('www') == 0)
		o = host.position();
		 
	var d = {height:host.height(), width:host.outerWidth()};
	var top = o.top + d.height + options.extratop + 5;
	var left = o.left + options.extraleft;
	var width = d.width + options.extrawidth - 1;
	popup.css({height:'auto', overflowY:'auto', display:'block', top:top, left:left, width:width});
	if(list.height() > options.maxheight)
		popup.css({height:options.maxheight, overflowY:'scroll'});
	list.find('LI').hover(MouseOver, MouseOut).click(Click);
	popup.scrollTop(0);
	host.focus();
	$(document).click(BodyClick);
	return true;
}
function BodyClick(event) {							
	$(document).unbind('click', BodyClick);
	var target = $(event.target);
	if(target.parents('#AutoComplete_'+id).length == 0)
	{
		popup.css({display:'none'});
		return;
	}

	list = $('#AutoComplete_'+id);				
	if (list == null)
		return;

	var selected = list.find('.mouseover');
	if (selected.length == 0) return;
	host.val(selected.text()).focus();		 
}

function ScrollToView() {
	var selected = list.find('.selected');
	if(selected.length == 0) return;
	var pos = selected.position().top;
	var max = popup.height() - selected.outerHeight();
	if(pos > max)
		popup.scrollTop(popup.scrollTop() + pos - max);
	if(pos < 0)
		popup.scrollTop(popup.scrollTop() + pos);
}
function HandleKey(event) {
	var selected = list.find('.selected');
	var keycode = event.which;
	if(keycode == 9) {
		// if there's only one choice, select it
		if(selected.length > 0 && list.find('LI').length == 1) {
			popup.css({display:'none'});
			host.val(selected.text()+' ').focus();
			return false;
		}
		if(event.shiftKey)
			keycode = 38; // shift+tab = up
		else
			keycode = 40; // tab = down
	}
	switch(keycode) {
		case 13:	// return when item selected, get text
			if(selected.length == 0)
			{				
				return true;
			}
			popup.css({display:'none'});
			host.val(selected.text()).focus();
			return true;
		case 40: // down selects the one below
			if(selected.length == 0) {
				list.find('LI:first').addClass('selected');
				ScrollToView();
				return false;
			}
			var next = selected.removeClass('selected').next();
			if(next.length == 0)
				list.find('LI:first').addClass('selected');
			else
				next.addClass('selected');
			ScrollToView();
			return false;
		case 38: // up selects the one on top
			if(selected.length == 0) {
				list.find('LI:last').addClass('selected');
				ScrollToView();
				return false;
			}
			var prev = selected.removeClass('selected').prev();
			if(prev.length == 0)
				list.find('LI:last').addClass('selected');
			else
				prev.addClass('selected');
			ScrollToView();
			return false;
		case 16: // shift by itself
			return true;
		case 33: //page up
			popup.scrollTop(popup.scrollTop() - popup.height());
			return false;
		case 34: // page down
			popup.scrollTop(popup.scrollTop() + popup.height());
			return false;
		case 27: // esc: disable autocomplete
			popup.css({display:'none'});
			host.attr('autocomplete', 'on');
			host.attr('AutoCompleted', 'false');
			host.unbind('keydown', HandleKey);
			return false;
		default:
			setTimeout(function() {Complete();}, 10);
			return true;
	}
}

function Complete(forceSeeAll) {
	if(!host || !popup || !list) return;
	seeAll = false;
	if (forceSeeAll) seeAll = true;
	var v = host.val();
	if(v.length < 3) {
		popup.css({display:'none'});
		return;
	}
	
	query = v.toLowerCase();
	var p = host.val().substring(0,i);
	prefix = ''
	if(p.length > 0)
		prefix = '<span class="before">'+p+' </span>';

	// check if we have a cache for the the full length down to the first 3 letters
	// if we do, call render and see if it's a valid one
	var cacheKey = query +'';
	var data = false;
	for(var i=query.length;i>2;i--) {
		cacheKey = query.substring(0, i);
		data = cache[cacheKey];
		if (typeof data != 'undefined')
			if(Render(data, query, cacheKey))
				return;
	}
	cacheKey = query + ''; // revert to the full key
	var data = {suggest:new Array()};
	var r = new RegExp(query, 'i');
	data.suggest = $.grep(Keywords, function(n,i) {return r.test(n);} );
	cache[cacheKey] = data;
	Render(data);
	// call the web service
	/*
	var url = "/ws.aspx?key=SUGGEST&q=" + query;
	if (pending) return;
	pending = true;
	setTimeout(function() {pending = false;}, 2000);
	$.getJSON(url,
		function(data){
			cache[cacheKey] = data;
			pending = false;
			Render(data);
		}
	);
	*/
}
function MouseOver() {
	$(this).addClass('mouseover');
}
function MouseOut(event) {
	$(this).removeClass('mouseover');
}
function Click(event) {
	if(!host) return;
	popup.css({display:'none'});
	host.val($(this).text()+' ').focus();
}
function Resized(event) {
	if($(window).width() != savedWidth)
		setTimeout(function() {Complete();}, 10);
	savedWidth = $(window).width();
}
var savedWidth = $(window).width();
$(window).bind('resize', Resized);
			
// look for options
var temp = host.parent().html();
var start = -1;
if(temp) 
	start = temp.indexOf('<!-- autocompleted.options');
if(start > -1) {
	temp = temp.substring(start + 26, temp.indexOf('-->', start))+' ';
	var extraleft = temp.indexOf('extraleft:');
	if(extraleft > -1)
		try {options.extraleft = parseInt(temp.substring(extraleft + 10, temp.indexOf(' ', extraleft + 10)));} catch(err) {}
	var extrawidth = temp.indexOf('extrawidth:');
	if(extrawidth > -1)
		try {options.extrawidth = parseInt(temp.substring(extrawidth + 11, temp.indexOf(' ', extrawidth + 11)));} catch(err) {}
	var extratop = temp.indexOf('extratop:');
	if(extratop > -1)
		try {options.extratop = parseInt(temp.substring(extratop + 9, temp.indexOf(' ', extratop + 9)));} catch(err) {}
	var maxheight = temp.indexOf('maxheight:');
	if(maxheight > -1)
		try {options.maxheight = parseInt(temp.substring(maxheight + 10, temp.indexOf(' ', maxheight + 10)));} catch(err) {}
	var altpos = temp.indexOf('altpos:');
	if(altpos > -1)
		try {options.altpos = temp.substring(maxheight + 10, temp.indexOf(' ', maxheight + 10));} catch(err) {}
	var achost = temp.indexOf('host:');
	if(achost > -1)
		try {options.host = temp.substring(achost + 5, temp.indexOf(' ', achost + 5));} catch(err) {}
	var match = temp.indexOf('match:');
	if(match > -1)
		try {options.match = temp.substring(match + 6, temp.indexOf(' ', match + 6));} catch(err) {}
}
var id = (''+Math.random()).substr(2);
var popupid = '__dsns_autocomplete_'+id;
if(host.data('dsnsAutoCompleted') == 'false')
	return;

if(host.data('dsnsAutoCompleted') == 'true') {
	popup = $('#'+popupid);
	seeAllLink = popup.find('A[href$=#all]');
	list = popup.find('UL');
	return;
}

host.attr('autocomplete', 'off');
host.data('dsnsAutoCompleted', 'true');
host.keydown(HandleKey);
var tmp = $(options.host);
if(tmp.length == 0)
	tmp = $('#loaderhost');
if(tmp.length == 0)
	tmp = $('BODY');
if($('#'+popupid).length == 0)
	tmp.append('<div id="'+popupid+'" class="dsnsAutoComplete"><ul></ul><a href="#all" class="dsnsAutoCompleteSeeAll">See all...</a></div>');

popup = $('#'+popupid);
seeAllLink = popup.find('A[href$=#all]');
list = popup.find('UL');
}; $('#advancedsearch, .dsnsadvsearch A, #header .advanced A, #search .advanced A').live('click', function() {
	var me = $(this);
	var id = me.data('dsns_quicksearch');
	if(!me.data('dsns_quicksearch')) {
		id = (''+Math.random()).substr(2);
		me.data('dsns_quicksearch', id);
	}
	
	var popupid = '__dsns_quicksearch_'+id;
	var popup = $('#'+popupid);

	var tmp = $('#loaderhost');
	if(tmp.length == 0)
		tmp = $('body');
			
	var created = false;
	if(popup.length == 0) {
		popup = $('<div id="'+popupid+'" class="dsnsQuickSearch"></div>').appendTo(tmp);
		popup.html(qsHTML.replace(/\{id\}/ig, id));
		created = true;
	}
	if(me.hasClass('dsnsoffset')) {
		var oft = me.offset();
		var l = oft.left + me.width() - popup.width();
		popup.css({display:'block', top: oft.top + 20, left: l});
	} else {
		var pos = me.position();
		popup.css({display:'block', top: pos.top + me.height(), left: -1000});
		popup.css({left:$('#header').width() - 50});
		if(me.attr('id') == 'advancedsearch') popup.css({top:220, left:380, marginTop:0});
	}
	if(!created) return false;
	
	function BodyClick(event) {							
		var target = $(event.target);
		if (!(target.parents().index(popup) >= 0 || target[0] == popup[0] || target[0].tagName == 'HTML')) {
			popup.css({display:'none'});
			return;
		}
	}
	$(document).mousedown(BodyClick);
	
	function Resized(event) {
		if($(window).width() != savedWidth)
			popup.css({display:'none'});
		savedWidth = $(window).width();
	}
	var savedWidth = $(window).width();
	$(window).bind('resize', Resized);
	
	popup.find('.close').click(function() {
		popup.css({display:'none'});
	});
	
	$('#qscity_' + id).bind('change', function() {
		var me = $(this);
		var city = me.find('OPTION:selected');
		var v = city.val();
		if(v && v.length > 0)
			$('#qscnty_' + id).attr('disabled', true).find('option[value="'+city.attr('rel')+'"]').attr('selected', 'selected');
		else
			$('#qscnty_' + id).attr('disabled', false);
	});
	
	popup.find('FORM').bind('submit', function() {
		var type = '', q = '', date = '';
		var me = $(this);
		q = me.find('.qstext').val();
		
		var cat = $('#qscat_' + id +' OPTION:selected').val();
		if(cat && cat.length > 0)
			type += $('#qscat_'+id).attr('rel') + ',' + cat + ';';
			
		var feat = $('#qsfeat_' + id +' OPTION:selected').val();
		if(feat && feat.length > 0)
			type += $('#qsfeat_'+id).attr('rel') + ',' + feat + ';';
		
		var city = $('#qscity_' + id +' OPTION:selected').val();
		if(city && city.length > 0)
			type += $('#qscity_'+id).attr('rel') + ',' + city + ';';
			
		var cnty = $('#qscnty_' + id +' OPTION:selected').val();
		if(cnty && cnty.length > 0)
			type += $('#qscnty_'+id).attr('rel') + ',' + cnty + ';';
		
		var date = $('#qsdate_' + id +' OPTION:selected').val();
		if(date && date.length > 0) {
			var d = new Date();
			d.setDate(d.getDate() - parseInt(date));
			var day = d.getDate();
			if(day < 10) day = '0'+day;
			var month = d.getMonth() + 1;
			if(month < 10) month = '0'+month;
			date = $('#qsdate_'+id).attr('rel') + '=' + month + '%2f' + day + '%2f' + d.getFullYear() + '%2c';
		}
		
		if(type.length > 0)
			type = type.substr(0, type.length - 1);
		
		var url = 'http://'+window.location.host.replace('www', 'search')+'/default.aspx?ct=r';
		if(q && q.length > 0)
			url += '&q="'+q+'"';
		if(type && type.length > 0)
			url += '&type='+type;
		if(date && date.length > 0)
			url += '&'+date;
		window.location = url;
		return false;
	});
	
	return false;
});  function AddDefaultText(box) {
	if(!box || box.length == 0 || box.data('defaulttext'))
		return;
	box.data('defaulttext', true);
	var t = box.attr('title');
	if (!t || typeof t != 'string')
		t = 'Search';
	box.blur(function() {
		var me = $(this).removeClass('hasfocus').addClass('isblurred');
		var v = me.val();
		if(v == '' || v == t)
			me.val(t);
	}).focus(function() {
		var me = $(this).removeClass('isblurred').addClass('hasfocus');
		var v = me.val();
		if(v == t)
			me.val('');
	});


	var v = box.val();
	if(v == '' || v == t)
		box.addClass('isblurred').val(t);

	var forms = box.parents('form');
	if(forms && forms.length > 0) {
		forms.each(function(n, f) {
			var p = $(f), u = p.attr('action') + '?ct=r&q=';
			p.submit(function() {
				var v = p.find('.autocompleted').val();
				if(v == t) v = '';
				window.location = u + v;
				return false;
			});
		});
	}
}

(function() {
setTimeout(function() {$('.autocompleted').each(function() {AddDefaultText($(this));});}, 10);
setTimeout(function() {$('.autocompleted').each(function() {AddDefaultText($(this));});}, 200);
setTimeout(function() {$('.autocompleted').each(function() {AddDefaultText($(this));});}, 500);
$(function() {$('.autocompleted').each(function() {AddDefaultText($(this));});});
})(); var localFeeds = new Array({"t":"Downtown", "u":"http://downtown.fox6now.com", "k":"downtown", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Racine band Wheelie Bar to open for KISS", "n":"45383"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336"},{"t":"House Speaker Nancy Pelosi speaks at American Legion convention", "n":"45349"} ]},{"t":"Bayside", "u":"http://bayside.fox6now.com", "k":"bayside", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Whitefish Bay homeowners look for answers at public meeting", "n":"45388", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922528-01195031.jpg"},{"t":"No classes yet for students of Nicolet High School", "n":"45367"},{"t":"Whitefish Bay residents set up neighborhood weather watch", "n":"45337"},{"t":"Police arrest man suspected of multiple burglaries in Whitefish Bay and Shorewood", "n":"45285"},{"t":"Bayside Police investigating missing street signs", "n":"45264"} ]},{"t":"Bay View", "u":"http://bayview.fox6now.com", "k":"bayview", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"19-year-old man shot, killed Wednesday night", "n":"45389", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55929117-02051401.jpg"},{"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336"},{"t":"Say \"thanks\" to those who serve and protect Milwaukee", "n":"45340"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"},{"t":"Recalled MPS teachers prepare for new school year", "n":"45286"} ]},{"t":"Brown Deer", "u":"http://browndeer.fox6now.com", "k":"browndeer", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55918204-01154621_0.jpg"},{"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336"},{"t":"Milwaukee area farmer\'s markets take part in Eat Local Challenge", "n":"45339"},{"t":"Some Milwaukee homeowners have backup plan if FEMA says no again", "n":"45338"},{"t":"Recalled MPS teachers prepare for new school year", "n":"45286"} ]},{"t":"Cudahy", "u":"http://cudahy.fox6now.com", "k":"cudahy", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370"},{"t":"Milwaukee County employee cited with OWI after appearing at hearing drunk", "n":"45362"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"} ]},{"t":"East Side", "u":"http://eastside.fox6now.com", "k":"eastside", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Racine band Wheelie Bar to open for KISS", "n":"45383"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336"},{"t":"House Speaker Nancy Pelosi speaks at American Legion convention", "n":"45349"} ]},{"t":"Fox Point", "u":"http://foxpoint.fox6now.com", "k":"foxpoint", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Whitefish Bay homeowners look for answers at public meeting", "n":"45388", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922528-01195031.jpg"},{"t":"No classes yet for students of Nicolet High School", "n":"45367"},{"t":"Whitefish Bay residents set up neighborhood weather watch", "n":"45337"},{"t":"Police arrest man suspected of multiple burglaries in Whitefish Bay and Shorewood", "n":"45285"},{"t":"Bayside Police investigating missing street signs", "n":"45264"} ]},{"t":"Franklin", "u":"http://franklin.fox6now.com", "k":"franklin", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/199741820-01161305.jpg"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Victim testifies in court against therapist accused of having sexual contact with patients", "n":"45099"},{"t":"City of Franklin considers allowing homeowners to grow lawns over 12 inches", "n":"45035"} ]},{"t":"Glendale", "u":"http://glendale.fox6now.com", "k":"glendale", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Whitefish Bay homeowners look for answers at public meeting", "n":"45388", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922528-01195031.jpg"},{"t":"No classes yet for students of Nicolet High School", "n":"45367"},{"t":"Whitefish Bay residents set up neighborhood weather watch", "n":"45337"},{"t":"Police arrest man suspected of multiple burglaries in Whitefish Bay and Shorewood", "n":"45285"},{"t":"Bayside Police investigating missing street signs", "n":"45264"} ]},{"t":"Greendale", "u":"http://greendale.fox6now.com", "k":"greendale", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/199741820-01161305.jpg"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Victim testifies in court against therapist accused of having sexual contact with patients", "n":"45099"},{"t":"City of Franklin considers allowing homeowners to grow lawns over 12 inches", "n":"45035"} ]},{"t":"Greenfield", "u":"http://greenfield.fox6now.com", "k":"greenfield", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/199741820-01161305.jpg"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Victim testifies in court against therapist accused of having sexual contact with patients", "n":"45099"},{"t":"City of Franklin considers allowing homeowners to grow lawns over 12 inches", "n":"45035"} ]},{"t":"Hales Corners", "u":"http://halescorners.fox6now.com", "k":"halescorners", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/199741820-01161305.jpg"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Victim testifies in court against therapist accused of having sexual contact with patients", "n":"45099"},{"t":"City of Franklin considers allowing homeowners to grow lawns over 12 inches", "n":"45035"} ]},{"t":"Midtown", "u":"http://midtown.fox6now.com", "k":"midtown", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55918204-01154621_0.jpg"},{"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336"},{"t":"Milwaukee area farmer\'s markets take part in Eat Local Challenge", "n":"45339"},{"t":"Some Milwaukee homeowners have backup plan if FEMA says no again", "n":"45338"},{"t":"Recalled MPS teachers prepare for new school year", "n":"45286"} ]},{"t":"North Shore", "u":"http://northshore.fox6now.com", "k":"northshore", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Whitefish Bay homeowners look for answers at public meeting", "n":"45388", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922528-01195031.jpg"},{"t":"No classes yet for students of Nicolet High School", "n":"45367"},{"t":"Whitefish Bay residents set up neighborhood weather watch", "n":"45337"},{"t":"Police arrest man suspected of multiple burglaries in Whitefish Bay and Shorewood", "n":"45285"},{"t":"Bayside Police investigating missing street signs", "n":"45264"} ]},{"t":"Northwest", "u":"http://northwest.fox6now.com", "k":"northwest", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55918204-01154621_0.jpg"},{"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336"},{"t":"Milwaukee area farmer\'s markets take part in Eat Local Challenge", "n":"45339"},{"t":"Some Milwaukee homeowners have backup plan if FEMA says no again", "n":"45338"},{"t":"Recalled MPS teachers prepare for new school year", "n":"45286"} ]},{"t":"Oak Creek", "u":"http://oakcreek.fox6now.com", "k":"oakcreek", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370"},{"t":"Milwaukee County employee cited with OWI after appearing at hearing drunk", "n":"45362"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"} ]},{"t":"River Hills", "u":"http://riverhills.fox6now.com", "k":"riverhills", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Whitefish Bay homeowners look for answers at public meeting", "n":"45388", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922528-01195031.jpg"},{"t":"No classes yet for students of Nicolet High School", "n":"45367"},{"t":"Whitefish Bay residents set up neighborhood weather watch", "n":"45337"},{"t":"Police arrest man suspected of multiple burglaries in Whitefish Bay and Shorewood", "n":"45285"},{"t":"Bayside Police investigating missing street signs", "n":"45264"} ]},{"t":"Riverwest", "u":"http://riverwest.fox6now.com", "k":"riverwest", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Racine band Wheelie Bar to open for KISS", "n":"45383"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336"},{"t":"House Speaker Nancy Pelosi speaks at American Legion convention", "n":"45349"} ]},{"t":"Shorewood", "u":"http://shorewood.fox6now.com", "k":"shorewood", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Whitefish Bay homeowners look for answers at public meeting", "n":"45388", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922528-01195031.jpg"},{"t":"No classes yet for students of Nicolet High School", "n":"45367"},{"t":"Whitefish Bay residents set up neighborhood weather watch", "n":"45337"},{"t":"Police arrest man suspected of multiple burglaries in Whitefish Bay and Shorewood", "n":"45285"},{"t":"Bayside Police investigating missing street signs", "n":"45264"} ]},{"t":"South Milwaukee", "u":"http://southmilwaukee.fox6now.com", "k":"southmilwaukee", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370"},{"t":"Milwaukee County employee cited with OWI after appearing at hearing drunk", "n":"45362"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"} ]},{"t":"South Shore", "u":"http://southshore.fox6now.com", "k":"southshore", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370"},{"t":"Milwaukee County employee cited with OWI after appearing at hearing drunk", "n":"45362"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"} ]},{"t":"Southwest", "u":"http://southwest.fox6now.com", "k":"southwest", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/199741820-01161305.jpg"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Victim testifies in court against therapist accused of having sexual contact with patients", "n":"45099"},{"t":"City of Franklin considers allowing homeowners to grow lawns over 12 inches", "n":"45035"} ]},{"t":"St. Francis", "u":"http://stfrancis.fox6now.com", "k":"stfrancis", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"PICTURES: Milwaukee Co. Sheriff Deputies respond to incident on Hoan Bridge", "n":"45397", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/202891440-02102435.jpg"},{"t":"Milwaukee Common Council passes proposal to sell flood victims $1 homes", "n":"45369"},{"t":"New signs urge drivers to be on the lookout for motorcycle riders", "n":"45370"},{"t":"Milwaukee County employee cited with OWI after appearing at hearing drunk", "n":"45362"},{"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314"} ]},{"t":"Third Ward", "u":"http://thirdward.fox6now.com", "k":"thirdward", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"80,000 MPS students hit the books for the start of a new school year", "n":"45336", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55902058-01154744_0.jpg"},{"t":"Fight at Mexican Fiesta injures two Milwaukee Police officers", "n":"45287"},{"t":"Recalled MPS teachers prepare for new school year", "n":"45286"},{"t":"President Obama visiting Milwaukee on Labor Day", "n":"45261"},{"t":"2010 Mexican Fiesta wraps up another successful year", "n":"45241"} ]},{"t":"Wauwatosa", "u":"http://wauwatosa.fox6now.com", "k":"wauwatosa", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Wauwatosa man works to get defibrillators for police department", "n":"45240", "i":"55852699-29202432-400225"},{"t":"Milwaukee Co. supervisors have plan to rebuild mental health complex", "n":"45229"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"45158"},{"t":"Seat belt saves Wauwatosa woman from carjacker", "n":"45140"} ]},{"t":"West Allis", "u":"http://westallis.fox6now.com", "k":"westallis", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55887487-31151042_4.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Milwaukee\'s largest fish fry serves up more than 20,000 pounds of fish", "n":"45166"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"45158"},{"t":"Tickets available for 5th Annual Forks and Corks event", "n":"45114"} ]},{"t":"Whitefish Bay", "u":"http://whitefishbay.fox6now.com", "k":"whitefishbay", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Whitefish Bay homeowners look for answers at public meeting", "n":"45388", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922528-01195031.jpg"},{"t":"No classes yet for students of Nicolet High School", "n":"45367"},{"t":"Whitefish Bay residents set up neighborhood weather watch", "n":"45337"},{"t":"Police arrest man suspected of multiple burglaries in Whitefish Bay and Shorewood", "n":"45285"},{"t":"Bayside Police investigating missing street signs", "n":"45264"} ]},{"t":"West Milwaukee", "u":"http://westmilwaukee.fox6now.com", "k":"westmilwaukee", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Milwaukee Police end south side standoff with tear gas", "n":"45314", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55887487-31151042_4.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Milwaukee\'s largest fish fry serves up more than 20,000 pounds of fish", "n":"45166"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"45158"},{"t":"Tickets available for 5th Annual Forks and Corks event", "n":"45114"} ]},{"t":"Beaver Dam", "u":"http://beaverdam.fox6now.com", "k":"beaverdam", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Call in your high school football scores to FOX6", "n":"http://dodge.fox6now.com/node/45197", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/HSblitz_400x225.jpg"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://dodge.fox6now.com/node/45185"},{"t":"4-year-old girl attacked, killed by dog in Iron Ridge", "n":"http://dodge.fox6now.com/node/45150"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"http://dodge.fox6now.com/node/45158"},{"t":"Enthusiasm Flies High At Model Plane Show: Warbirds and Classics Over the Midwest", "n":"http://dodge.fox6now.com/node/45077"} ]},{"t":"Cedarburg", "u":"http://cedarburg.fox6now.com", "k":"cedarburg", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Free car seat safety check at Costco", "n":"45390"},{"t":"Join Saukville\'s Family 5k Run/Walk", "n":"45121"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Register now for the Punt, Pass & Kick competition", "n":"45120"},{"t":"Alex Wilson Band to perform at final Cedarburg Summer Sounds concert", "n":"45115"} ]},{"t":"Dodge Co.", "u":"http://dodge.fox6now.com", "k":"dodge", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Firefighter Appreciation Night at the Races", "n":"45399", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/8_7_001.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"45185"},{"t":"4-year-old girl attacked, killed by dog in Iron Ridge", "n":"45150"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"45158"} ]},{"t":"Grafton", "u":"http://grafton.fox6now.com", "k":"grafton", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Free car seat safety check at Costco", "n":"45390"},{"t":"Join Saukville\'s Family 5k Run/Walk", "n":"45121"},{"t":"Doggy Paddle Day benefits local humane society", "n":"44820"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Register now for the Punt, Pass & Kick competition", "n":"45120"} ]},{"t":"Germantown", "u":"http://germantown.fox6now.com", "k":"germantown", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Waukesha County plans to upgrade communication technologies by 2012", "n":"45365"},{"t":"Lilly Road closed Sept. 1-3", "n":"45315"},{"t":"Grocery wars heat up in Menomonee Falls", "n":"45272"},{"t":"President Obama visits ZBB Energy Corp. in Menomonee Falls", "n":"44868"},{"t":"Call in your high school football scores to FOX6", "n":"45197"} ]},{"t":"Hartford", "u":"http://hartford.fox6now.com", "k":"hartford", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Pedestrian dies after being hit by several vehicles", "n":"45387", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55930483-02065447.jpg"},{"t":"Main Street closed at railroad crossing this week", "n":"45263"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"West Bend to collect storm debris through Friday", "n":"45146"},{"t":"Strong winds deal massive damage to homes near Silver Lake", "n":"45072"} ]},{"t":"Jackson", "u":"http://jackson.fox6now.com", "k":"jackson", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Main Street closed at railroad crossing this week", "n":"http://hartford.fox6now.com/node/45263"},{"t":"Call in your high school football scores to FOX6", "n":"http://hartford.fox6now.com/node/45197"},{"t":"West Bend to collect storm debris through Friday", "n":"http://hartford.fox6now.com/node/45146"},{"t":"Strong winds deal massive damage to homes near Silver Lake", "n":"http://hartford.fox6now.com/node/45072"},{"t":"Storm slams neighborhoods in West Bend, uproots trees", "n":"http://hartford.fox6now.com/node/45061"} ]},{"t":"Mequon", "u":"http://mequon.fox6now.com", "k":"mequon", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Free car seat safety check at Costco", "n":"45390"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Register now for the Punt, Pass & Kick competition", "n":"45120"},{"t":"55 dogs rescued from small Kentucky shelter brought to Milwaukee", "n":"45044"},{"t":"Study says only 17% of drivers buckle up dogs", "n":"44988"} ]},{"t":"Port Washington", "u":"http://portwashington.fox6now.com", "k":"portwashington", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Join Saukville\'s Family 5k Run/Walk", "n":"http://grafton.fox6now.com/node/45121", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/Saukville_Run_Walk_1.jpg"},{"t":"Doggy Paddle Day benefits local humane society", "n":"http://grafton.fox6now.com/node/44820"},{"t":"Call in your high school football scores to FOX6", "n":"http://grafton.fox6now.com/node/45197"},{"t":"Register now for the Punt, Pass & Kick competition", "n":"http://grafton.fox6now.com/node/45120"},{"t":"55 dogs rescued from small Kentucky shelter brought to Milwaukee", "n":"http://grafton.fox6now.com/node/45044"} ]},{"t":"Saukville", "u":"http://saukville.fox6now.com", "k":"saukville", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Join Saukville\'s Family 5k Run/Walk", "n":"http://grafton.fox6now.com/node/45121", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/Saukville_Run_Walk_1.jpg"},{"t":"Doggy Paddle Day benefits local humane society", "n":"http://grafton.fox6now.com/node/44820"},{"t":"Call in your high school football scores to FOX6", "n":"http://grafton.fox6now.com/node/45197"},{"t":"Register now for the Punt, Pass & Kick competition", "n":"http://grafton.fox6now.com/node/45120"},{"t":"55 dogs rescued from small Kentucky shelter brought to Milwaukee", "n":"http://grafton.fox6now.com/node/45044"} ]},{"t":"Slinger", "u":"http://slinger.fox6now.com", "k":"slinger", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Main Street closed at railroad crossing this week", "n":"http://hartford.fox6now.com/node/45263"},{"t":"Call in your high school football scores to FOX6", "n":"http://hartford.fox6now.com/node/45197"},{"t":"West Bend to collect storm debris through Friday", "n":"http://hartford.fox6now.com/node/45146"},{"t":"Strong winds deal massive damage to homes near Silver Lake", "n":"http://hartford.fox6now.com/node/45072"},{"t":"Storm slams neighborhoods in West Bend, uproots trees", "n":"http://hartford.fox6now.com/node/45061"} ]},{"t":"Thiensville", "u":"http://thiensville.fox6now.com", "k":"thiensville", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Call in your high school football scores to FOX6", "n":"http://mequon.fox6now.com/node/45197", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/HSblitz_400x225.jpg"},{"t":"Register now for the Punt, Pass & Kick competition", "n":"http://mequon.fox6now.com/node/45120"},{"t":"55 dogs rescued from small Kentucky shelter brought to Milwaukee", "n":"http://mequon.fox6now.com/node/45044"},{"t":"Study says only 17% of drivers buckle up dogs", "n":"http://mequon.fox6now.com/node/44988"},{"t":"Construction crew strikes gas line in Mequon", "n":"http://mequon.fox6now.com/node/44926"} ]},{"t":"Watertown", "u":"http://watertown.fox6now.com", "k":"watertown", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Call in your high school football scores to FOX6", "n":"http://dodge.fox6now.com/node/45197", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/HSblitz_400x225.jpg"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://dodge.fox6now.com/node/45185"},{"t":"4-year-old girl attacked, killed by dog in Iron Ridge", "n":"http://dodge.fox6now.com/node/45150"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"http://dodge.fox6now.com/node/45158"},{"t":"Enthusiasm Flies High At Model Plane Show: Warbirds and Classics Over the Midwest", "n":"http://dodge.fox6now.com/node/45077"} ]},{"t":"Waupun", "u":"http://waupun.fox6now.com", "k":"waupun", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Call in your high school football scores to FOX6", "n":"http://dodge.fox6now.com/node/45197", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/HSblitz_400x225.jpg"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://dodge.fox6now.com/node/45185"},{"t":"4-year-old girl attacked, killed by dog in Iron Ridge", "n":"http://dodge.fox6now.com/node/45150"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"http://dodge.fox6now.com/node/45158"},{"t":"Enthusiasm Flies High At Model Plane Show: Warbirds and Classics Over the Midwest", "n":"http://dodge.fox6now.com/node/45077"} ]},{"t":"West Bend", "u":"http://westbend.fox6now.com", "k":"westbend", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Main Street closed at railroad crossing this week", "n":"http://hartford.fox6now.com/node/45263"},{"t":"Call in your high school football scores to FOX6", "n":"http://hartford.fox6now.com/node/45197"},{"t":"West Bend to collect storm debris through Friday", "n":"http://hartford.fox6now.com/node/45146"},{"t":"Strong winds deal massive damage to homes near Silver Lake", "n":"http://hartford.fox6now.com/node/45072"},{"t":"Storm slams neighborhoods in West Bend, uproots trees", "n":"http://hartford.fox6now.com/node/45061"} ]},{"t":"Waukesha", "u":"http://waukesha.fox6now.com", "k":"waukesha", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Waukesha County plans to upgrade communication technologies by 2012", "n":"45365"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"45185"},{"t":"Waukesha-made camera allows world to see rescue of Chilean miners", "n":"45165"},{"t":"Radio personality wants Waukesha to be WauKe$ha Thursday", "n":"45122"} ]},{"t":"Brookfield", "u":"http://brookfield.fox6now.com", "k":"brookfield", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Waukesha County plans to upgrade communication technologies by 2012", "n":"45365"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"45185"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"45158"},{"t":"Free sports injury clinic at MCW", "n":"45119"} ]},{"t":"Delafield", "u":"http://delafield.fox6now.com", "k":"delafield", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"2010 Parade of Homes seeing best attendance in years", "n":"http://lakecountry.fox6now.com/node/45230", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55813891-27153258_0.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"http://lakecountry.fox6now.com/node/45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://lakecountry.fox6now.com/node/45185"},{"t":"Hybrid school buses come to Oconomowoc", "n":"http://lakecountry.fox6now.com/node/45167"},{"t":"Arrowhead Cross Country Course named in honor of Coach Mulrooney", "n":"http://lakecountry.fox6now.com/node/45097"} ]},{"t":"Elm Grove", "u":"http://elmgrove.fox6now.com", "k":"elmgrove", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Call in your high school football scores to FOX6", "n":"http://brookfield.fox6now.com/node/45197", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/HSblitz_400x225.jpg"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://brookfield.fox6now.com/node/45185"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"http://brookfield.fox6now.com/node/45158"},{"t":"Free sports injury clinic at MCW", "n":"http://brookfield.fox6now.com/node/45119"},{"t":"55 dogs rescued from small Kentucky shelter brought to Milwaukee", "n":"http://brookfield.fox6now.com/node/45044"} ]},{"t":"Hartland", "u":"http://hartland.fox6now.com", "k":"hartland", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"2010 Parade of Homes seeing best attendance in years", "n":"http://lakecountry.fox6now.com/node/45230", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55813891-27153258_0.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"http://lakecountry.fox6now.com/node/45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://lakecountry.fox6now.com/node/45185"},{"t":"Hybrid school buses come to Oconomowoc", "n":"http://lakecountry.fox6now.com/node/45167"},{"t":"Arrowhead Cross Country Course named in honor of Coach Mulrooney", "n":"http://lakecountry.fox6now.com/node/45097"} ]},{"t":"Lake Country", "u":"http://lakecountry.fox6now.com", "k":"lakecountry", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Waukesha County plans to upgrade communication technologies by 2012", "n":"45365"},{"t":"2010 Parade of Homes seeing best attendance in years", "n":"45230"},{"t":"Call in your high school football scores to FOX6", "n":"45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"45185"},{"t":"Hybrid school buses come to Oconomowoc", "n":"45167"} ]},{"t":"Menomonee Falls", "u":"http://menomoneefalls.fox6now.com", "k":"menomoneefalls", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Waukesha County plans to upgrade communication technologies by 2012", "n":"45365"},{"t":"Lilly Road closed Sept. 1-3", "n":"45315"},{"t":"Grocery wars heat up in Menomonee Falls", "n":"45272"},{"t":"President Obama visits ZBB Energy Corp. in Menomonee Falls", "n":"44868"},{"t":"Call in your high school football scores to FOX6", "n":"45197"} ]},{"t":"Muskego", "u":"http://muskego.fox6now.com", "k":"muskego", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Call in your high school football scores to FOX6", "n":"http://waukesha.fox6now.com/node/45197", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/HSblitz_400x225.jpg"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://waukesha.fox6now.com/node/45185"},{"t":"Waukesha-made camera allows world to see rescue of Chilean miners", "n":"http://waukesha.fox6now.com/node/45165"},{"t":"Radio personality wants Waukesha to be WauKe$ha Thursday", "n":"http://waukesha.fox6now.com/node/45122"},{"t":"Watertown Police searching for man they say robbed Aurora Pharmacy", "n":"http://waukesha.fox6now.com/node/45158"} ]},{"t":"Oconomowoc", "u":"http://oconomowoc.fox6now.com", "k":"oconomowoc", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"2010 Parade of Homes seeing best attendance in years", "n":"http://lakecountry.fox6now.com/node/45230", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55813891-27153258_0.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"http://lakecountry.fox6now.com/node/45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://lakecountry.fox6now.com/node/45185"},{"t":"Hybrid school buses come to Oconomowoc", "n":"http://lakecountry.fox6now.com/node/45167"},{"t":"Arrowhead Cross Country Course named in honor of Coach Mulrooney", "n":"http://lakecountry.fox6now.com/node/45097"} ]},{"t":"Okauchee", "u":"http://okauchee.fox6now.com", "k":"okauchee", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"2010 Parade of Homes seeing best attendance in years", "n":"http://lakecountry.fox6now.com/node/45230", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55813891-27153258_0.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"http://lakecountry.fox6now.com/node/45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://lakecountry.fox6now.com/node/45185"},{"t":"Hybrid school buses come to Oconomowoc", "n":"http://lakecountry.fox6now.com/node/45167"},{"t":"Arrowhead Cross Country Course named in honor of Coach Mulrooney", "n":"http://lakecountry.fox6now.com/node/45097"} ]},{"t":"Pewaukee", "u":"http://pewaukee.fox6now.com", "k":"pewaukee", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"2010 Parade of Homes seeing best attendance in years", "n":"http://lakecountry.fox6now.com/node/45230", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55813891-27153258_0.jpg"},{"t":"Call in your high school football scores to FOX6", "n":"http://lakecountry.fox6now.com/node/45197"},{"t":"Waukesha Police end standoff with a suspect wanted for armed robbery", "n":"http://lakecountry.fox6now.com/node/45185"},{"t":"Hybrid school buses come to Oconomowoc", "n":"http://lakecountry.fox6now.com/node/45167"},{"t":"Arrowhead Cross Country Course named in honor of Coach Mulrooney", "n":"http://lakecountry.fox6now.com/node/45097"} ]},{"t":"Racine Co.", "u":"http://racine.fox6now.com", "k":"racine", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Racine band Wheelie Bar to open for KISS", "n":"45383", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/55922789-01194948.jpg"},{"t":"Sign up for the Skeleton Skamper Run/Walk", "n":"45377"},{"t":"Three school principals go to extreme length to win combined $1.5M in funding", "n":"45288"},{"t":"Caledonia teen shoots at group of teens committing revenge vandalism", "n":"45284"},{"t":"Call in your high school football scores to FOX6", "n":"45197"} ]},{"t":"Kenosha Co.", "u":"http://kenosha.fox6now.com", "k":"kenosha", "lp":"/node/", "ip":"/sites/fox6now.com/files/imagecache/story_image_widget/",  "i": [ {"t":"Call in your high school football scores to FOX6", "n":"45197", "i":"http://hlcdn.datasphere.com/sites/fox6now.com/files/imagecache/story_image_widget/HSblitz_400x225.jpg"},{"t":"Aurora Health Care will not charge Trevor Hall for ER services", "n":"45193"},{"t":"Cousins save drowning teen at Kenosha County\'s Silver Lake", "n":"45144"},{"t":"Rescuer looking to be rescued from his medical bills", "n":"45177"},{"t":"Block Watch captains, participant help recover stolen vehicle", "n":"45081"} ]}); var host = window.location.host.replace('search.', 'www.').replace('.test.datasphere', '').replace('.regisweb', '').replace('dev.', '');
var GetLocationFromGoogleLoader = function(callback) {
	var AjaxGeoLocation = (function() {
		var loading = false;
		var loadGoogleLoader = function() {
			if (!hasGoogleLoader() && !loading) { loading = true; var s = document.createElement('script'); s.src = 'http://www.google.com/jsapi?callback=_google_loader_apiLoaded'; s.type = "text/javascript"; document.getElementsByTagName('head')[0].appendChild(s); }
		};
		var queue = [];
		var addLocationQueue = function(callback) { queue.push(callback); }
		var runLocationQueue = function() {
			if (hasGoogleLoader()) while (queue.length > 0) { var call = queue.pop(); call(); }
		}

		window['_google_loader_apiLoaded'] = function() { runLocationQueue(); }
		var hasGoogleLoader = function() { return (window['google'] && google['loader']); }
		var checkGoogleLoader = function(callback) { if (hasGoogleLoader()) return true; addLocationQueue(callback); loadGoogleLoader(); return false; };
		loadGoogleLoader();
		return { shim: true, type: "ClientLocation", lastPosition: null,
			getCurrentPosition: function(successCallback) {
				var self = this;
				if (!checkGoogleLoader(function() { self.getCurrentPosition(successCallback); })) return;
				if (google.loader.ClientLocation) {
					var cl = google.loader.ClientLocation;
					var position = { latitude: cl.latitude, longitude: cl.longitude, altitude: null, accuracy: 43000, altitudeAccuracy: null, heading: null, velocity: null, timestamp: new Date(),
						address: { city: cl.address.city, country: cl.address.country, country_code: cl.address.country_code, region: cl.address.region }
					};
					successCallback(position);
					this.lastPosition = position;
				} else {
					successCallback(false);
				}
			}
		};
	})();
	AjaxGeoLocation.getCurrentPosition(function(pos) { if(/debugfeeds/ig.test(window.location.href)) window['dsnsloc'] = {'gpos':pos}; if(pos) callback(pos.address.city.toLowerCase()); else callback(false); });
}

var CommunityFromCity = function(city) {
var cities = {'seattle':'ballard', 'eugene':'downtowneugene', 'portland':'beaverton', 'bakersfield':'central', 'boise':'boisebench'};
	return cities[city] || city;
}
var GetLocationFromAdManager = function(callback) {
	var loc = window['__dsns_'].GetCookie('dsnsloc');
	if (loc) callback(CommunityFromCity(loc));
	else callback(false);
}

var GetLocationFromCookie = function(callback) {
	var loc = window['__dsns_'].GetCookie('dsnscomm');
	if (loc) callback(loc);
	else callback(false);
}
var adHider = false;
var HideFlash = function() {
	$('object, embed, iframe').each(function() {
		var me = $(this);
		if(me.data('hiddenflash')) return;
		if(me.css('visibility') != 'hidden') {
			me.data('hiddenflash', true);
			me.css({visibility:'hidden'});
		}
	});
}
var ShowFlash = function() {
	$('object, embed, iframe').each(function() {
		var me = $(this);
		if(me.data('hiddenflash'))
			me.css({visibility:'visible'});
			me.data('hiddenflash', false);
	});
}

var AddOverlay = function(needElement) {
	var mask = $('#dsnsOverlay');
	if(window.top != window.self) {
		window.top['__dsns_'].AddOverlay(true);
		return;
	}
	if(mask.length == 0 && needElement)
		mask = $('<div id="dsnsOverlay">&nbsp;</div>').appendTo($('body')).css({display:'none'});
	if(mask.length == 0 || mask.is(':visible'))
		return;
	var w = $(window).width();
	var h = $(window).height();
	var dw = $(document).width();
	var dh = $(document).height();
	if(dh>h)h=dh;
	if(dw>w)w=dw;
	if(IE6 || IE8) w -= 22;
	if(IE6) $('SELECT').css({visibility:'hidden'});
	mask.css({position:'absolute', opacity:.0, backgroundColor:'#333', top:0, left:0, width:w, height:h,display:'block', zIndex:19999, opacity:.4});
	HideFlash();
	adHider = setInterval(function() {HideFlash();}, 500);
	return this;
}
window['__dsns_'].AddOverlay = AddOverlay;

var RemoveOverlay = function(outto) {
	clearInterval(adHider);
	if(outto) {
		var pos = outto.position();
		if(pos.left || pos.top == 0) pos = outto.offset();
		$('#dsnsOverlay').css({height:$(window).height(), backgroundColor:'#5B8CBE'}).animate({opacity:.0, top:pos.top, left:pos.left, width:outto.width(), height:outto.height()}, 500, function() {$(this).hide();ShowFlash();if(IE6) $('SELECT').css({visibility:'visible'});});
	}
	else
		$('#dsnsOverlay').animate({opacity:.0}, 300, function() {$(this).hide();ShowFlash();if(IE6) $('SELECT').css({visibility:'visible'});});
	return this;
}
var tmplBck = false;
var RenderLocalDeals = function(host, tmpl, comm) {
	LocalDealsRendered = true;
	var LocalDealsFound = false;
	host = host || $('#dsnslocaldeals').hide();
	if(tmpl == 'undefined') tmpl = false;
	tmpl = tmpl || tmplBck || GetMetaData(host.hide().html(lfHTML).find('#dsnsbizdir'));
	comm = comm || (window['__dsns_'].LocalFeed?window['__dsns_'].LocalFeed.k:false) || __dsns_.GetCookie('dsnscomm');
	if(!comm) comm = 'all';
	if(!tmplBck) tmplBck = tmpl;
	host.find('.title').text('fetching deals...');
	$.ajax({
		url:'http://content.secondspace.com//ld/'+comm+'.js',
		dataType:'script', 
		success:function() {
			if(typeof __dsns_.BusinessFeed != 'object' || __dsns_.BusinessFeed.length < 1) return;
			LocalDealsFound = true;
			host.html(tmpl).find('.business, .smalllist, .biglist').hide();
			var cfg = __dsns_.BusinessFeedConfig;
			var max = 6;
			if(__dsns_.BusinessFeed.length < max) max = __dsns_.BusinessFeed.length;
			var arr = $(__dsns_.BusinessFeed).sort(function(){ 
					return Math.round(Math.random())-0.5
				}).slice(0,max)
			for(var i=0;i<max&&i<3;i++) {
				var b = $('.business'+(i+1)), x = arr[i];
				x.link = cfg.root + '/' + x.name.replace(/\W+/ig, '_')+'/'+x.id+'.html';
				b.find('.name').html('<a href="'+x.link+'">'+x.name+'</a>');
		
				var k = x.logo.indexOf('http://hlocal.');
				if(k>-1)
					x.logo = x.logo.substr(k);
				else
					x.logo = cfg.imgroot+x.logo;
				k = x.logo.indexOf('http://hlcdn.');
				if(k>-1)
					x.logo = x.logo.substr(k);
				
				b.find('.thumb').html('<a href="'+x.link+'"><img src="'+x.logo+'" /></a>');
				if(!x.video) b.find('.video').hide();
				else b.find('.video').show().find('A').attr('href', x.link);
				if(!x.coupon) b.find('.coupon').hide();
				else b.find('.coupon .text').show().html('<a href="'+x.link+'?o='+x.oid+'">'+x.coupon+'</a>');
				host.find('.biglist').show();
				b.show();
			}

			//max = 3;
			//if(__dsns_.CouponFeed.length < max) max = __dsns_.CouponFeed.length;
			//arr = $(__dsns_.CouponFeed).sort(function(){
			//		return Math.round(Math.random())-0.5
			 // }).slice(0,max)
 
			for(var i=3;i<max;i++) {
				var b = $('.business'+(i+1)), x = arr[i];
				x.link = cfg.root + '/' + x.name.replace(/\W+/ig, '_')+'/'+x.id+'.html';
				b.find('.name').html('<a href="'+x.link+'">'+x.name+'</a>');
				b.find('.coupon').show().html('<a href="'+x.link+'?o='+x.oid+'">'+x.coupon+'</a>');
				host.find('.smalllist').show();
				b.show();
			}

			var t = 'Local deals';
			if(comm != 'all') {
				t = comm+' deals';
				if(window['__dsns_'].LocalFeed)
					t = window['__dsns_'].LocalFeed.t+' deals';
			}
			host.find('.title').text(t);
			host.find('.change A').click(function() {
				if($('#dsnsLfPopup').length == 0) {
					host.after($('<div/>').hide().html(lfHTML));
				}
				window['__dsns_'].ShowPicker();
				return false;
			});
			host.show(); 
		}
	});
	setTimeout(function() {if(!LocalDealsFound) RenderLocalDeals(host, tmpl, 'all'); }, 2000);
}
function RenderFeed(source) {
	var dealsHost = $('#dsnslocaldeals');
	window['__dsns_'].LocalFeed = source;
	if(dealsHost && dealsHost.length > 0)
		RenderLocalDeals(dealsHost, dsnsLFHTMLTemplates.deals + '', source.k);

	$('#dsnslocalnews, #dsnslocallinks').hide().find('*').show();
	var newshtml = dsnsLFHTMLTemplates.news + '';
	var linkshtml = dsnsLFHTMLTemplates.links + '';
	newshtml = newshtml.replace(/community_name/ig, source.t);
	newshtml = newshtml.replace(/http:\/\/community_link/ig, source.u);
	linkshtml = linkshtml.replace(/community_name/ig, source.t);
	linkshtml = linkshtml.replace(/http:\/\/community_link/ig, source.u);
	var img = source.i[0].i;

	if (!img || img.length < 1) {
		img = false;
		newshtml = newshtml.replace(/http:\/\/the_image./ig, 'http://cdn.secondspace.com/fshr/blank.gif');
	} else {
		var k = img.indexOf('http://hlocal.');
		if(k>-1)
			img = img.substr(k);
		else
			img = source.u + source.ip + source.i[0].i;
		k = img.indexOf('http://hlcdn.');
		if(k>-1)
			img	= img .substr(k);
				 
		newshtml = newshtml.replace(/http:\/\/the_image./ig, img);
	}

	newshtml = newshtml.replace(/http:\/\/first_link./ig, source.u + source.lp + source.i[0].n);
	newshtml = newshtml.replace(/first_title/ig, source.i[0].t);

	if (source.i.length > 1) {
		newshtml = newshtml.replace(/http:\/\/second_link./ig, source.u + source.lp + source.i[1].n);
		newshtml = newshtml.replace(/second_title/ig, source.i[1].t);
	}
	if (source.i.length > 2) {
		newshtml = newshtml.replace(/http:\/\/third_link./ig, source.u + source.lp + source.i[2].n);
		newshtml = newshtml.replace(/third_title/ig, source.i[2].t);
	}
	if (source.i.length > 3) {
		newshtml = newshtml.replace(/http:\/\/fourth_link./ig, source.u + source.lp + source.i[3].n);
		newshtml = newshtml.replace(/fourth_title/ig, source.i[3].t);
	}
	if (source.i.length > 4) {
		newshtml = newshtml.replace(/http:\/\/fifth_link./ig, source.u + source.lp + source.i[4].n);
		newshtml = newshtml.replace(/fifth_title/ig, source.i[4].t);
	}

	$('#dsnslocalnews').html(newshtml);
	$('#dsnslocallinks').html(linkshtml);
	if(window.top != window.self)
		$('#dsnslocalnews A, #dsnslocallinks A').attr('target', '_top');
		
	if (source.i.length < 2) $('#dsnslocalnews .second').hide();
	if (source.i.length < 3) $('#dsnslocalnews .third').hide();
	if (source.i.length < 4) $('#dsnslocalnews .fourth').hide();
	if (source.i.length < 5) $('#dsnslocalnews .fifth').hide();
	if(img) $('#dsnslocalnews .localimg').show();
	$('#dsnslocalnews, #dsnslocallinks').show();
}
window['__dsns_'].RenderFeed = RenderFeed;

function GetDefault() {
	if('eastside'.length > 0) return 'eastside';
	var cities = {'www.katu.com':'portland', 'www.kval.com':'eugene', 'www.komonews.com':'seattle', 'www.kionrightnow.com':'monterey', 'www.kcba.com':'monterey', 'www.myfox11.com':'santabarbara', 'www.kcoy.com':'santabarbara', 'www.abc6.com':'warwick', 'www.bakersfieldnow.com':'bakersfield', 'www.kboi2.com':'boise'};
	var pick = cities[host];
	if(pick) return CommunityFromCity(pick);
	return CommunityFromCity('seattle');
}
var dsnsLFHTMLTemplates = {news:'', links:''};
function ShowFeeds(picked) {
	var defcom = GetDefault();
	if (!picked)
		picked = defcom;
	
	var com = false, dcom = false;;
	var communityList = new Array();

	function feedSort(a, b) {
		var A = a.t.charAt(0), B = b.t.charAt(0);
		return A > B ? 1 : A < B ? -1 : 0;
	}
	localFeeds.sort(feedSort);

	$.each(localFeeds, function(i, c) {
		if (c.i.length == 0)
			c.i.push({"t":"No News Yet", "n":"0", "i":false});
	});
	if(/debugfeeds/ig.test(window.location.href))
		window['dsnsTemp'] = {localFeeds:localFeeds, defcom:defcom};

	window['__dsns_'].LocalFeeds = localFeeds;
	$.each(localFeeds, function(i, c) {
		if (c.i.length == 0) return true;
		communityList.push('<li><a href="#pick' + i + '">' + c.t + '</a></li>');
		if (c.k == picked) com = c;
		if (c.k == defcom) dcom = c;
	});
	if (!com) com = dcom;
	if (!com || communityList.length == 0) {
		$('#dsnslocal').show();
		return;
	}
	
	lfHTML = lfHTML.replace('<!--', '<pre><!--').replace('-->', '--></pre>').replace('<pre><pre>', '<pre>').replace('</pre></pre>', '</pre>');
	$('#dsnslocal').hide().html(lfHTML);
	dsnsLFHTMLTemplates.news = GetMetaData($('#dsnslocalnews'));
	dsnsLFHTMLTemplates.links = GetMetaData($('#dsnslocallinks'));
	dsnsLFHTMLTemplates.deals = GetMetaData($('#dsnsbizdir'));
	if($('#fin_maincontainer').length > 0) { // new layout
		if($('#dsnslocalnews2').length > 0) dsnsLFHTMLTemplates.news = GetMetaData($('#dsnslocalnews2'));
		if($('#dsnslocallinks2').length > 0) dsnsLFHTMLTemplates.links = GetMetaData($('#dsnslocallinks2'));
	}
	RenderFeed(com);


	$('#dsnspickcommunity').hide().find('UL').html(communityList.join(''));
	$('#dsnspickcommunity UL LI A').live('click', function() {
		$('#dsnspickcommunity').hide();
		var sel = localFeeds[parseInt(/[0-9]+$/.exec($(this).attr('href')))];
		RenderFeed(sel);
		window['__dsns_'].SetCookie('dsnscomm', sel.k);
		return false;
	});
	$('#dsnslocalnews').find('a[href$="pickcommunity"]').live('click', function() {
		setTimeout(function() {ShowPicker();}, 100);
		return false;
	});
	$('#dsnslocal').show();

	var autoPopup = false;
	if(host == 'www.komonews.com' || host == 'www.kionrightnow.com'	|| host == 'www.kcba.com'	||
		 host == 'www.kcoy.com'	|| host == 'www.myfo11.com' || 'true' == 'true')
		 autoPopup = true;
	if(autoPopup) {
		var c1 = window['__dsns_'].GetCookie('dsnsloc');
		var c2 = window['__dsns_'].GetCookie('dsnscomm');
		var c3 = window['__dsns_'].GetCookie('dsnslfpop');
		var date = new Date();
		if((c1 && !c2 && !c3) || c3 && c3 != '1')
		{
			try {
				if(date.getTime() > parseInt(c3))
				{
					date.setTime(date.getTime()+(30*24*60*60*1000));
					window['__dsns_'].SetCookie('dsnslfpop', '1', date.toGMTString());
					setTimeout(function() {ShowPicker();}, 100);
				}
			} catch(e) {}
		}
		if(!c2 && !c1 && !c3) {
				date.setTime(date.getTime()+(3*24*60*60*1000));
				window['__dsns_'].SetCookie('dsnslfpop', date.getTime());
		}
	}
}
var HidePicker = function(outto) {
	RemoveOverlay(outto);
	$('#dsnsLfPopup, #dsnsLfPopup2').hide();
	if(IE) $('BODY').css({position:''});
}

var ShowPicker = function(target, outto, linkoff) {
	if(window.top != window.self) {
		window.top['__dsns_'].ShowPicker(window.self);
		return;
	}
	if(IE && $('#fin_maincontainer').length > 0 && $('#footer').length == 0) {
		setTimeout(function() {ShowPicker();}, 500);
		return;
	}
	if(!window['__dsns_'].GetCookie('dsnsloc')) {
		var date = new Date();
		date.setTime(date.getTime()+(30*24*60*60*1000));
		window['__dsns_'].SetCookie('dsnslfpop', '1', date.toGMTString());
	}
	if($('#header #dsnsOverlay').length == 0 && $('BODY > #dsnsOverlay').length == 0)
	{
		$('#dsnsOverlay').prependTo($('BODY')).hide();
		$('#dsnsLfPopup').prependTo($('BODY'));
	}
		
	var p = $('#dsnsLfPopup2');
	if(!p || p.length < 1)
		p = $('#dsnsLfPopup');
		
	var t = $('#dsnslocal');
	if(target) { // we need to copy the popup in here
		if(!p || p.length == 0) {
			p = $('<div id="dsnsLfPopup"> </div>').appendTo($('body'));
			p.html($(target.document).find('#dsnsLfPopup').html());
		}
		t = $(target.frameElement);
	}
		
	setTimeout(function() {AddOverlay(target || outto);p.find('A').css({color:''});}, 10);
	p.css({left:-1000,top:-1000}).show();
	var ww = $(window).width();
	var wh = $(window).height();
	var dl = $(document).scrollLeft();
	var dt = $(document).scrollTop();
	var ew = p.width();
	var eh = p.height();
	var left = (ww - ew) / 2 + dl;
	var top = (wh - eh) / 2 + dt;
	if(top < 10) top = 10;
	if(left < 10) left = 10;
	p.css({left:left,top:top});
	if(!p.data('bound')) {
		p.data('bound', true);
		p.find('A[href$=close], .closeButton').click(function() {
			HidePicker();
			return false;
		});
		p.find('.column A').click(function() {
			var href = $(this).attr('href');
			var i = href.indexOf('#'), k=4;
			while(i == -1 && k-- > 0)
			{
				href = decodeURIComponent(href);
				i = href.indexOf('#');
			}
			if(i==-1) {
				HidePicker();
				return false;
			}
			
			n = href.substr(i+1);
			var com = false;
				
			$.each(localFeeds, function(i, c) {
				if (c.k == n) {
					com = c;
					return false;
				}
			});
			if(com) {
				window['__dsns_'].SetCookie('dsnscomm', com.k);
				if(linkoff) {
					window.location = href.substr(0, href.indexOf('#'));
					return false;
				}
			
				if(typeof window['__dsns_'].selectBusinesses == 'function')
					window['__dsns_'].selectBusinesses();
				if(target) 
					target['__dsns_'].RenderFeed(com);
				else
					RenderFeed(com);
				HidePicker(target || outto);
			} else
				HidePicker();
			return false;
		});
	}
}
window['__dsns_'].ShowPicker = ShowPicker;

var LocalDealsRendered = false;
var dealsReady = function() {
	if(LocalDealsRendered) return;
	var max = 100;
	if ($('#dsnslocaldeals').length == 0 || typeof window['__dsns_'] != 'object') {
		if(max-- > 0)
			setTimeout(function() { dealsReady(); }, 100);
		return;
	}
	RenderLocalDeals();
}
var localReady = function() {	
	var max = 100;
	if ($('#dsnslocal').length == 0 || typeof window['__dsns_'] != 'object') {
		if(max-- > 0)
			setTimeout(function() { localReady(); }, 100);
		return;
	}
	GetLocationFromCookie(function(city) {
		if (city) ShowFeeds(city);
		else GetLocationFromAdManager(function(city) {
			if (city) ShowFeeds(city);
			else GetLocationFromGoogleLoader(function(city) {
				if (city) ShowFeeds(CommunityFromCity(city));
				else ShowFeeds(false);
			});
		});
	});
}
localReady();dealsReady(); var localBusiness = new Array({'k':'downtown', 'u':'/witi/lb/downtown.js'},{'k':'bayside', 'u':'/witi/lb/bayside.js'},{'k':'bayview', 'u':'/witi/lb/bayview.js'},{'k':'browndeer', 'u':'/witi/lb/browndeer.js'},{'k':'cudahy', 'u':'/witi/lb/cudahy.js'},{'k':'eastside', 'u':'/witi/lb/eastside.js'},{'k':'foxpoint', 'u':'/witi/lb/foxpoint.js'},{'k':'glendale', 'u':'/witi/lb/glendale.js'},{'k':'franklin', 'u':'/witi/lb/franklin.js'},{'k':'greendale', 'u':'/witi/lb/greendale.js'},{'k':'greenfield', 'u':'/witi/lb/greenfield.js'},{'k':'halescorners', 'u':'/witi/lb/halescorners.js'},{'k':'midtown', 'u':'/witi/lb/midtown.js'},{'k':'northshore', 'u':'/witi/lb/northshore.js'},{'k':'northwest', 'u':'/witi/lb/northwest.js'},{'k':'oakcreek', 'u':'/witi/lb/oakcreek.js'},{'k':'riverhills', 'u':'/witi/lb/riverhills.js'},{'k':'riverwest', 'u':'/witi/lb/riverwest.js'},{'k':'shorewood', 'u':'/witi/lb/shorewood.js'},{'k':'southmilwaukee', 'u':'/witi/lb/southmilwaukee.js'},{'k':'southshore', 'u':'/witi/lb/southshore.js'},{'k':'southwest', 'u':'/witi/lb/southwest.js'},{'k':'stfrancis', 'u':'/witi/lb/stfrancis.js'},{'k':'thirdward', 'u':'/witi/lb/thirdward.js'},{'k':'wauwatosa', 'u':'/witi/lb/wauwatosa.js'},{'k':'westallis', 'u':'/witi/lb/westallis.js'},{'k':'westmilwaukee', 'u':'/witi/lb/westmilwaukee.js'},{'k':'whitefishbay', 'u':'/witi/lb/whitefishbay.js'},{'k':'beaverdam', 'u':'/witi/lb/beaverdam.js'},{'k':'cedarburg', 'u':'/witi/lb/cedarburg.js'},{'k':'dodge', 'u':'/witi/lb/dodge.js'},{'k':'grafton', 'u':'/witi/lb/grafton.js'},{'k':'germantown', 'u':'/witi/lb/germantown.js'},{'k':'hartford', 'u':'/witi/lb/hartford.js'},{'k':'jackson', 'u':'/witi/lb/jackson.js'},{'k':'mequon', 'u':'/witi/lb/mequon.js'},{'k':'portwashington', 'u':'/witi/lb/portwashington.js'},{'k':'saukville', 'u':'/witi/lb/saukville.js'},{'k':'slinger', 'u':'/witi/lb/slinger.js'},{'k':'thiensville', 'u':'/witi/lb/thiensville.js'},{'k':'watertown', 'u':'/witi/lb/watertown.js'},{'k':'waupun', 'u':'/witi/lb/waupun.js'},{'k':'westbend', 'u':'/witi/lb/westbend.js'},{'k':'waukesha', 'u':'/witi/lb/waukesha.js'},{'k':'brookfield', 'u':'/witi/lb/brookfield.js'},{'k':'delafield', 'u':'/witi/lb/delafield.js'},{'k':'elmgrove', 'u':'/witi/lb/elmgrove.js'},{'k':'hartland', 'u':'/witi/lb/hartland.js'},{'k':'lakecountry', 'u':'/witi/lb/lakecountry.js'},{'k':'menomoneefalls', 'u':'/witi/lb/menomoneefalls.js'},{'k':'muskego', 'u':'/witi/lb/muskego.js'},{'k':'muskego', 'u':'/witi/lb/muskego.js'},{'k':'oconomowoc', 'u':'/witi/lb/oconomowoc.js'},{'k':'okauchee', 'u':'/witi/lb/okauchee.js'},{'k':'pewaukee', 'u':'/witi/lb/pewaukee.js'},{'k':'racine', 'u':'/witi/lb/racine.js'},{'k':'kenosha', 'u':'/witi/lb/kenosha.js'}); var savedHeight = false;
var HideLocalBiz = function() {
	$('#dsnslocalbiz').css({display:'none'});
	if(!savedHeight) savedHeight = $('#dsnslocallinks').height();
	$('#dsnslocallinks').css({height:'auto'});
}
var bizReady = function() {	
	var max = 100;
	if ($('#dsnslocalbiz').length == 0 || typeof window['__dsns_'] != 'object') {
		if(max == 0) HideLocalBiz();
		if(max-- > 0)
			setTimeout(function() { bizReady (); }, 100);
		return;
	}
	window['__dsns_'].localBusinesses = new Array();
	var FindBiz = function(key) {
		if(typeof window['__dsns_'].localBusinesses != 'object') return false;
		var f = false;
		$.each(window['__dsns_'].localBusinesses, function(i,b)	{
			if(b.k == key) f = b;
			return (f == false);
		});
		return f;
	}
	var FindBizOnCDN = function(key, callback) {
		var found = false;
		if(key) $.each(localBusiness, function(n,v) {
			if(v.k == key) {
if(/debugfeeds/ig.test(window.location.href))	__dsns_.cdnbiz = v;
				$.getScript('http://content.secondspace.com'+v.u, callback);
				found = true;
				return false;
			}
		});
		if(!found) callback();
	}
	var RenderBiz = function(b) {
if(/debugfeeds/ig.test(window.location.href)) __dsns_.biz = b;
		if(!b || b.i.length == 0) {HideLocalBiz();return;}
		var r = Math.floor(Math.random()*b.i.length);
		var x = b.i[r];
		if(savedHeight) $('#dsnslocallinks').css({height:savedHeight});

		var img = x.i;
		var k = img.indexOf('http://hlocal.');
		if(k>-1)
			img = img.substr(k);
		else
			img = b.u+b.ip+img;
		k = img.indexOf('http://hlcdn.');
		if(k>-1)
			img = img .substr(k);

		$('#dsnslocalbiz').html(lbHTML.replace(/the_title/ig, x.t).replace(/the_link/ig, b.u+b.lp+x.n+'?utm_source=homepage_widget&utm_medium=referral&utm_campaign=na').replace(/the_img/ig, img));

		if($('#fin_maincontainer').length > 0) // new layout
			$('#dsnslocalbiz .oldlayout').hide();
		else
			$('#dsnslocalbiz .newlayout').hide();
		$('#dsnslocalbiz').css({display:'block'});
	}
	window['__dsns_'].selectBusinesses = function() {
		var c = window['__dsns_'].GetCookie('dsnscomm');
		var b = FindBiz(c);
		if(b) {
			RenderBiz(b);
			return;
		}
		FindBizOnCDN(c, function() {
			b = FindBiz(c);
			if(!b) b = FindBiz('eastside');
			if(!b) {
				FindBizOnCDN('eastside', function() {
					b = FindBiz('eastside');
					RenderBiz(b);
				});
				return;
			}
			RenderBiz(b);
		});
	}
	window['__dsns_'].selectBusinesses();
}
bizReady();
		
		var Ready = function(ready_host) {
			if(window[ds_plugin_name].IsReady) return;
			window[ds_plugin_name].IsReady = true;
			if(typeof $ == 'undefined')
			{
				if(ready_host && typeof ready_host.$ == 'function')
					$ = window[ds_plugin_name].$ = ready_host.$;
				else 
					$ = window[ds_namespace].$;
			}
			if(typeof $ == 'undefined')
				return;
			var boxes = $('.autocompleted');
if(IE)
	$(function(){boxes.each(function() {Autocomplete($(this));});});
else
	boxes.each(function() {
		Autocomplete($(this));
	});
if($('#dsnslocalbiz').length == 0) $('#dsnslocallinks').css({height:'auto'}); $('#advancedsearch, .dsnsadvsearch A, #header .advanced A, #search .advanced A').click(function() {
	var me = $(this);
	var id = me.data('dsns_quicksearch');
	if(!me.data('dsns_quicksearch')) {
		id = (''+Math.random()).substr(2);
		me.data('dsns_quicksearch', id);
	}
	
	var popupid = '__dsns_quicksearch_'+id;
	var popup = $('#'+popupid);

	var tmp = $('#loaderhost');
	if(tmp.length == 0)
		tmp = $('body');
			
	var created = false;
	if(popup.length == 0) {
		popup = $('<div id="'+popupid+'" class="dsnsQuickSearch"></div>').appendTo(tmp);
		popup.html(qsHTML.replace(/\{id\}/ig, id));
		created = true;
	}
	if(me.hasClass('dsnsoffset')) {
		var oft = me.offset();
		var l = oft.left + me.width() - popup.width();
		popup.css({display:'block', top: oft.top + 20, left: l});
	} else {
		var pos = me.position();
		popup.css({display:'block', top: pos.top + me.height(), left: -1000});
		popup.css({left:$('#header').width() - 50});
		if(me.attr('id') == 'advancedsearch') popup.css({top:220, left:380, marginTop:0});
	}
	if(!created) return false;
	
	function BodyClick(event) {							
		var target = $(event.target);
		if (!(target.parents().index(popup) >= 0 || target[0] == popup[0] || target[0].tagName == 'HTML')) {
			popup.css({display:'none'});
			return;
		}
	}
	$(document).mousedown(BodyClick);
	
	function Resized(event) {
		if($(window).width() != savedWidth)
			popup.css({display:'none'});
		savedWidth = $(window).width();
	}
	var savedWidth = $(window).width();
	$(window).bind('resize', Resized);
	
	popup.find('.close').click(function() {
		popup.css({display:'none'});
	});
	
	$('#qscity_' + id).bind('change', function() {
		var me = $(this);
		var city = me.find('OPTION:selected');
		var v = city.val();
		if(v && v.length > 0)
			$('#qscnty_' + id).attr('disabled', true).find('option[value="'+city.attr('rel')+'"]').attr('selected', 'selected');
		else
			$('#qscnty_' + id).attr('disabled', false);
	});
	
	popup.find('FORM').bind('submit', function() {
		var type = '', q = '', date = '';
		var me = $(this);
		q = me.find('.qstext').val();
		
		var cat = $('#qscat_' + id +' OPTION:selected').val();
		if(cat && cat.length > 0)
			type += $('#qscat_'+id).attr('rel') + ',' + cat + ';';
			
		var feat = $('#qsfeat_' + id +' OPTION:selected').val();
		if(feat && feat.length > 0)
			type += $('#qsfeat_'+id).attr('rel') + ',' + feat + ';';
		
		var city = $('#qscity_' + id +' OPTION:selected').val();
		if(city && city.length > 0)
			type += $('#qscity_'+id).attr('rel') + ',' + city + ';';
			
		var cnty = $('#qscnty_' + id +' OPTION:selected').val();
		if(cnty && cnty.length > 0)
			type += $('#qscnty_'+id).attr('rel') + ',' + cnty + ';';
		
		var date = $('#qsdate_' + id +' OPTION:selected').val();
		if(date && date.length > 0) {
			var d = new Date();
			d.setDate(d.getDate() - parseInt(date));
			var day = d.getDate();
			if(day < 10) day = '0'+day;
			var month = d.getMonth() + 1;
			if(month < 10) month = '0'+month;
			date = $('#qsdate_'+id).attr('rel') + '=' + month + '%2f' + day + '%2f' + d.getFullYear() + '%2c';
		}
		
		if(type.length > 0)
			type = type.substr(0, type.length - 1);
		
var url = 'http://'+window.location.host.replace('www', 'search')+'/default.aspx?ct=r';
		if(q && q.length > 0)
			url += '&q="'+q+'"';
		if(type && type.length > 0)
			url += '&type='+type;
		if(date && date.length > 0)
			url += '&'+date;
		window.location = url;
		return false;
	});
	
	return false;
}); 
		}
		window[ds_plugin_name].Ready = Ready;
		window[ds_plugin_name].FullyInitialized = true;

		if(init_host)
			init_host.OnReady.push(window[ds_plugin_name].Ready);
		else
			$(function(){window[ds_plugin_name].Ready();});
	}
	Ready = false;
	
	return {
		Load: Load,
		WaitForInit: WaitForInit,
		Init: Init,
		WaitForReady: WaitForReady,
		WaitForBody: WaitForBody,
		Ready: Ready,
		GetCookie: GetCookie,
		SetCookie: SetCookie
	};
}();
//window[ds_plugin_name].WaitForBody();
window[ds_plugin_name].Load();

})();
if(typeof window['__dsns_'] == 'undefined') window['__dsns_'] = {};
window['__dsns_'].GetCookie = window['WITI_WidgetsV1'].GetCookie;
window['__dsns_'].SetCookie = window['WITI_WidgetsV1'].SetCookie;