function clickConnect(){
	var url = 'index.php?option=com_content&view=section&id=21&Itemid=128';
	window.open(url);
}
function openJoinUs() {
	var jUMenu = "<div id='menu2'>" 
	jUMenu += "<ul><li><h3><a href='index.php?option=com_jevents&task=month.calendar&Itemid=57'>Service/Event Times</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_content&view=category&layout=blog&id=116&Itemid=133'>Map</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_contact&view=category&catid=72&Itemid=87'>Contact Us</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_content&view=section&id=20&Itemid=126'>Small Groups</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_content&view=article&id=66&Itemid=46'>Worship Ministry</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_content&view=category&layout=blog&id=31&Itemid=109'>Prayer Ministry</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_content&view=article&id=237&Itemid=68'>Jail Ministry</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_content&view=article&id=73&Itemid=77'>Look Up Ministry</a></h3></li>";
	jUMenu += "<li><h3><a href='index.php?option=com_content&view=article&id=241&Itemid=69'>Love In Deed</a></h3></li></ul>";
	jUMenu += "</div>";
	Windows.closeAll();
	var navWin = new Window({className:"default", title: "", parent: "main",left:0, top:-23, width:308, height:336, zIndex: 100, resizable: true, showEffect:Effect.Appear, hideEffect: Effect.Fade, draggable:true, wiredDrag: true})
	navWin.getContent().innerHTML= jUMenu;
	navWin.show();                                      
}
function closeAllOpen() {
	Windows.closeAll();
}
function openPastSermons() {
	Windows.closeAll();
	var navWin = new Window({className:"default", title: "", parent: "main",left:0, top:-23, width:308, height:336, zIndex: 100, resizable: true, showEffect:Effect.Appear, hideEffect: Effect.Fade, draggable:true, wiredDrag: true})
	navWin.getContent().innerHTML= "<div id= 'menu2'></div>";
	navWin.show();
    var url = 'latestmp3s.php'
    var target = 'menu2'
    var myAjax = new Ajax.Updater(target,url,{method: 'get'})
}
function upHit(id)
{
    var url = 'uphit.php'
    var target = 'article'
    var pars = 'id=' + id
    var myAjax = new Ajax.Updater(target,url,{method: 'get', parameters:pars})	
}

function showLatest()
{
    var url = 'latestmp3.php'
    var target = 'article'
    var myAjax = new Ajax.Updater(target,url,{method: 'get'})
}

function showFile(retURL)
{ 
xmlHttp=GetXmlHttpObject();
if (xmlHttp==null)
 {
 alert ("Browser does not support HTTP Request");
 return
 }
var url=retURL
xmlHttp.onreadystatechange=stateChanged;
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
}




function showNavFile(retURL)
{ 
xmlHttp=GetXmlHttpObject();
if (xmlHttp==null)
 {
 alert ("Browser does not support HTTP Request");
 return
 }
var url=retURL
xmlHttp.onreadystatechange=stateChanged2;
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
}

function stateChanged2() 
{ 
if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
 { 
 document.getElementById("navMenu").innerHTML=xmlHttp.responseText 
 } 
}

function GetXmlHttpObject()
{
var xmlHttp=null;
try
 {
 // Firefox, Opera 8.0+, Safari
 xmlHttp=new XMLHttpRequest();
 }
catch (e)
 {
 //Internet Explorer
 try
  {
  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
  }
 catch (e)
  {
  xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
 }
return xmlHttp;
}