/* Norton Internet Security interferes and causes problems
   with a-d-r-e-l-a-t-e-d code, the D is changed to an X
   as a workaround. The Ax-section is also separated from
   the main SF-section using extend. */
Object.extend(SF, {

	Ax: {
		Adtoma: {
			init: function(cat, city, film, layout) {
				try{
					var protocolString = "";
					protocolString += location.protocol; 
					protocolString = protocolString.substring(0, (protocolString.length-1));
					if (!window.Fusion){ window.Fusion = {}; }
					var s = "";
	//				s += "\n <scr" + "ipt type=\"text/javascript\" src=\""+ location.protocol +"//" + "fusion.adtoma.com/scr" + "ipt.js\"></scr" + "ipt>";
	//				s += "\n <scr" + "ipt type=\"text/javascript\" src=\"http://fusion.adtoma.com/scr" + "ipt.js\"></scr" + "ipt>";
					s += "\n <scr" + "ipt type=\"text/javascript\">";
					s += "\n window.Fusion.adServer = \"fusion.adtoma.com\";";
					s += "\n window.Fusion.mediaZone = \"sf."+ cat +"\";";
	//				s += "\n window.Fusion.mediaZone = \"sf.www."+ cat +"\";";
					s += "\n window.Fusion.layout = \""+ layout +"\";";
					s += "\n window.Fusion.parameters[\"sf_film\"] = \""+ film +"\";";
					s += "\n window.Fusion.parameters[\"sf_stad\"] = \""+ city +"\";";
					s += "\n window.Fusion.parameters[\"sf_typ\"] = \""+ protocolString +"\";";
					s += "\n window.Fusion.loadAds();";
					s += "\n </scr" + "ipt>";
				 	s += "\n <scr" + "ipt type=\"text/javascript\"> window.Fusion.space(\"rm\");</scr" + "ipt>";
					document.write(s);
				} catch (error){
					//do nothing
				}
			},
			show: function(id) {
				try{
					if (typeof window.Fusion.space != "undefined"){	window.Fusion.space(id);}
				} catch (error){
					//do nothing
				}
			}
/*			init: function(cat, city, film) {
				var protocolString = "";
				protocolString += location.protocol; 
				protocolString = protocolString.substring(0, (protocolString.length-1));				
				var s = "";
				s += "\n <scr" + "ipt type=\"text/javascript\">";
				s += "\n var CM8Server = \"a" + "d.adtoma.com\";";
				s += "\n var CM8Cat = \"SF." + cat + "\";";
				s += "\n var CM8Profile = \"SF_stad=" + city + (film ? "&SF_film=" + film : "") + "&SF_Typ=" + protocolString +"\";";
				s += "\n </scr" + "ipt>";
				s += "\n <scr" + "ipt type=\"text/javascript\" src=\""+ location.protocol +"//a" + "d.adtoma.com/adam/cm8adam_1_call.js\"></scr" + "ipt>";
				document.write(s);
			},
		
			show: function(id) {
				if (typeof CM8ShowAd != "undefined")
					CM8ShowAd(id);
			}
*/
		},
		
		Emediate: {
			init: function(city) {
				try{
					this.city = city;
					var s = "";
					s += "\n <scr" + "ipt type=\"text/javascript\" src=\""+ location.protocol +"//a" + "d1.emediate.dk/EAS_tag.1.0.js\"></scr" + "ipt>";
					if (SF.Cookie.read("ngCity") != city) {
						s += "\n <img src=\""+ location.protocol +"//a" + "d1.emediate.dk/eas?camp=16612;cre=img;cat="+ city +";\" width=\"1\" height=\"1\" />";
						SF.Cookie.createPersistent("ngCity", city);
					} else {
						s += "\n <img src=\""+ location.protocol +"//a" + "d1.emediate.dk/eas?camp=16613;cre=img;cat="+ city +";\" width=\"1\" height=\"1\" />";
					}
					document.write(s);
				} catch (error){
					//do nothing
				}
			},
		
			show: function(id) {
				try{
					document.write("<scr" + "ipt type=\"text/javascript\" src=\""+ location.protocol +"//a" + "d1.emediate.dk/eas?cu="+ id +";cre=mu;js=y;target=_blank;cat="+ this.city +"\"></scr" + "ipt>");
				} catch (error){
					//do nothing
				}
			}
		},
		
		Google: {
			init: function(city) {
				try{
					var s = "";
					s += "\n <scr" + "ipt type=\"text/javascript\">";
					s += "\n     google_a" + "d_client = \"pub-5302288723411877\";";
					s += "\n     google_alternate_color = \"660000\";";
					s += "\n     google_a" + "d_width = 250;";
					s += "\n     google_a" + "d_height = 250;";
					s += "\n     google_a" + "d_format = \"250x250_as\";";
					s += "\n     google_a" + "d_type = \"text\";";
					s += "\n     google_a" + "d_channel = \"0740377094\";";
					s += "\n     google_color_border = \"000000\";";
					s += "\n     google_color_bg = \"660000\";";
					s += "\n     google_color_link = \"FFFFFF\";";
					s += "\n     google_color_text = \"FFFFFF\";";
					s += "\n     google_color_url = \"FFCC66\";";
					s += "\n </scr" + "ipt>";
					document.write(s);
				} catch(error){
					//do  nothing
				}
			},
			
			show: function() {
				try{
					document.write("<scr" + "ipt type=\"text/javascript\" src=\"http://pagea" + "d2.googlesyndication.com/pagea" + "d/show_a" + "ds.js\"></scr" + "ipt>");
				} catch (error){
					//do nothing
				}
			}
		}
	}
});