document.write('<div id="NoticiasHome"></div>');
document.write('<link href="http://www.portalfitness.com/styles/styles.css" type="text/css" rel="stylesheet" />');

function asbGetXmlHttp()
{
	var oXmlHttp=false;

	// -----> This method was provided from Jim Ley's website 
	/*@cc_on @*/
	/*@if (@_jscript_version >= 5)
	// JScript gives us Conditional compilation, we can cope with old IE versions.
	// and security blocked creation of the objects.
	try {
		oXmlHttp = new ActiveXObject("Msxml2.XMLHTTP");
	} catch (e) {
	try {
		oXmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
	} catch (E) {
		oXmlHttp = false;
	}
	}
	/*@end @*/


	if (!oXmlHttp && typeof XMLHttpRequest!='undefined') 
	{
		oXmlHttp = new XMLHttpRequest();
	}
	
	return oXmlHttp;	  
}	
	

function getNoticias()
{
	var oXmlHttp;
	oXmlHttp=asbGetXmlHttp();
	
	var domain = location.hostname;
	
	oXmlHttp.open("GET", "http://" + domain + "/NoticiasHome.aspx?m=7", true);
	
	oXmlHttp.onreadystatechange=function() 
	{
		if (oXmlHttp.readyState==4) 
			setDivNoticiasHome("NoticiasHome", oXmlHttp.responseText);
	}
	
	oXmlHttp.send(null)
}

function getArticulos()
{
	var oXmlHttp;
	oXmlHttp=asbGetXmlHttp();

	var domain = location.hostname;
	
	oXmlHttp.open("GET", "http://" + domain + "/NoticiasHome.aspx?tn=ARTICULO&m=7", true);
	
	oXmlHttp.onreadystatechange=function() 
	{
		if (oXmlHttp.readyState==4) 
			setDivNoticiasHome("ArticulosHome", oXmlHttp.responseText);
	}
	
	oXmlHttp.send(null)
}

function setDivNoticiasHome(sDivID, sDivContent)
{
	var divMenu;
	divMenu=document.getElementById(sDivID);
	
	var sInnerHtml;

	//Use IFrame of the same size as div		
	//if (isIE()) 
	//{
	//	sInnerHtml = "<div id='" + sDivID + "_content' style='z-index:9050; position:asbolute;'>";
	//	sInnerHtml += sDivContent;
	//	sInnerHtml += "</div><iframe id='" + sDivID + "_iframe' src='about:blank' frameborder='1' scrolling='no'></iframe>";
	//}
	//else
	//{
		sInnerHtml=sDivContent;
	//}
	
	divMenu.innerHTML = sInnerHtml;
	
	
	/*if (isIE()) 
	{
		var divContent;
		divContent=document.getElementById(sDivID + "_content");
		
		var divIframe;
		divIframe=document.getElementById(sDivID + "_iframe");
				
		divIframe.style.width = divContent.offsetWidth + 'px';
		divIframe.style.height = divContent.offsetHeight + 'px';
		divIframe.marginTop = "-" + divContent.offsetHeight + 'px';

	}*/
}


function isIE()
{
	return ( navigator.appName=="Microsoft Internet Explorer" ); 
}


function isNav()
{
	return ( navigator.appName=="Netscape" );
}

getNoticias();
getArticulos();

