
function ShowTwitterFeedPopup(TwitterFeed)
{
     var popWin = null;
     var windowstring;

     popWin = window.open("about:blank", "popWin", "width=550,height=545,scrollbars=1,location=No");
     
     
     
     
     popWin.document.write('<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title></title><link href="template/StyleSheet.css" rel="stylesheet" type="text/css" /><SCRIPT language="JavaScript">function silentErrorHandler(){return true;}window.onerror=silentErrorHandler;</SCRIPT><style>.links{color:#FC5492;text-decoration:none;}a.links{color:#FC5492;text-decoration:none;}a.links:hover{color:#FC5492;text-decoration:none;}</style></head><body bgcolor="#FA5492">');
     
     popWin.document.write('<div id="loginmainbox1" style="width:472px;margin-left:auto;margin-right:auto;"><div style="width:36px;height:36px;padding:0px;margin:0px;float:left;" ><img src="images/top_leftcorner.gif" width="36" height="36" alt="Free Business Advertising - Top Left Corner" title="Free Business Advertising - Top Left Corner"/></div><div style="width:400px;height:36px;padding:0px;margin:0px;float:left;background-color:#404040;"></div><div style="width:36px;height:36px;padding:0px;margin:0px;float:left;"><img src="images/top_rightcorner.gif" width="36" height="36" alt="Business UK Directory - Top Right Corner" title="Business UK Directory - Top Right Corner"/></div>');
     popWin.document.write('<div id="twitterinnercontent" style="background-color:#404040;min-height:300px;padding:0 10px 0 10px;color:White;font-family: Arial,tahoma,Verdana,Helvetica, sans-serif;font-size:15px;width:452px;margin-left:auto;margin-right:auto;"><div style="float:left;"><div style="float:left;padding:0px;"><img src="images/twitter.gif" alt="Business Directory - Twitter Feed" title="Business Directory - Twitter Feed"/></div><div style="float:left;padding:0px;padding:5px 0px 0px 10px;"><div class="middleheader" >Twitter<span style="color:#27D1E8">LIVE</span></div>Here&#39;s what we are saying on Twitter right now...</div></div><div style="clear:both;"></div><table cellpadding="0" cellspacing="0" style="margin-left:auto;margin-right:auto;"><tr><td>');
     
     popWin.document.write(TwitterFeed);
     
     popWin.document.write('</td></tr></table><div style="float:left;text-align:center;width:100%;"><a class="links" onclick="javascript:window.close()" href="#">Click here</a> to close this window.</div><div style="clear:both"></div></div><div style="width:36px;height:36px;padding:0px;margin:0px;float:left;" ><img src="images/bottom_leftcorner.gif" width="36" height="36" alt="Free Business Advertising - Bottom Left Corner" title="Free Business Advertising - Bottom Left Corner"/></div><div style="width:400px;height:36px;padding:0px;margin:0px;float:left;background-color:#404040;"></div><div style="width:36px;height:36px;padding:0px;margin:0px;float:left;"><img src="images/bottom_rightcorner.gif" width="36" height="36" alt="Business UK Directory - Bottom Right Corner" title="Business UK Directory - Bottom Right Corner"/></div></div></body></html>');
     popWin.focus();
     
     var browser=navigator.appName;
     if(browser!="Netscape")
     {
     	popWin.location.reload();
    }
     
}

/*
function blink1(){ 
blink_x = 1 
blink_y = 1 
ticToc(); 
} 
function ticToc(){ 
if(blink_x==1){ 
blink_x=0; 
blink_y++; 
document.getElementById("blink").style.visibility='visible'; 
//$(".blink").style.visibility='visible'; 
}else { 
blink_x=1; 
blink_y++; 
document.getElementById("blink").style.visibility='hidden'; 
//$(".blink").style.visibility='hidden'; 
} 
if (blink_y < 20) {settimeout('ticToc()', 100);} 
} 



<!-- 
var b_timer = null; // blink timer 
var b_on = true; // blink state 
var blnkrs = null; // array of spans 

function blink() { 
var tmp = document.getElementsByTagName("Div"); 
if (tmp) { 
blnkrs = new Array(); 
var b_count = 0; 
for (var i = 0; i < tmp.length; ++i) { 
if (tmp[i].className == "offer") { 
blnkrs[b_count] = tmp[i]; 
++b_count; 
} 
} 
// time in m.secs between blinks 
// 500 = 1/2 second 
blinkTimer(2500); 
} 
} 

function blinkTimer(ival) { 
if (b_timer) { 
window.clearTimeout(b_timer); 
b_timer = null; 
} 
blinkIt(); 
b_timer = window.setTimeout('blinkTimer(' + ival + ')', ival); 
} 

function blinkIt() { 
for (var i = 0; i < blnkrs.length; ++i) { 
if (b_on == true) { 
blnkrs[i].style.visibility = "hidden"; 
} 
else { 
blnkrs[i].style.visibility = "visible"; 
} 
} 
b_on =!b_on; 
} 
//--> 

*/

function hidehomemap() {
    var img = document.getElementById("ctl00_imgmap");
    var imgclose = document.getElementById("ctl00_imgmapclose");
    img.style.visibility = "hidden";
    img.style.display = "none";
    imgclose.style.visibility = "visible";
    

}

function trimString(str)
{
	  while (str.charAt(0) == ' ')
	    str = str.substring(1);
	  while (str.charAt(str.length - 1) == ' ')
	    str = str.substring(0, str.length - 1);
	  return str;
}
    


function chk_search()
{
    
    var obj1=document.getElementById("ctl00_txtwhat");

    var obj2 = document.getElementById("ctl00_txtwhere");
    
    
        
    if(trimString(obj1.value)=="search for...?" && trimString(obj2.value)=="in town...?")
    {
        alert("Please enter what you are searching for and where then simply hit go");
        if(trimString(obj1.value)=="")
            obj1.focus()
        else    
            obj2.focus()
        return false;
        
    }
        
}

 function AddNewRatingHandler() {

        AjaxControlToolkit.RatingBehavior.prototype._onStarClick =
            function(e) {
                if (this._readOnly) {
                    return;
                }
                //   if (this._ratingValue != this._currentRating) {                    
                this.set_Rating(this._currentRating);
                // }
            };
            AjaxControlToolkit.RatingBehavior.prototype.set_Rating = function(value) {                    
                //   if (this._ratingValue != value) {
                this._ratingValue = value;
                this._currentRating = value;
                if (this.get_isInitialized()) {
                    if ((value < 0) || (value > this._maxRatingValue)) {
                        return;
                    }

                    this._update();

                    AjaxControlToolkit.RatingBehavior.callBaseMethod(this, 'set_ClientState', [this._ratingValue]);
                    this.raisePropertyChanged('Rating');
                    this.raiseRated(this._currentRating);
                    this._waitingMode(true);

                    var args = this._currentRating + ";" + this._tag;
                    var id = this._callbackID;

                    if (this._autoPostBack) {
                        __doPostBack(id, args);
                    }
                    else {
                        WebForm_DoCallback(id, args, this._receiveServerData, this, this._onError, true)
                    }

                }
                //  }
            };                
    }

/*
function chk_register_business()
{
    var fname=document.getElementById("ctl00$ContentPlaceHolder1$fname");
    var lname=document.getElementById("ctl00$ContentPlaceHolder1$lname");
    var company=document.getElementById("ctl00$ContentPlaceHolder1$company");
    var street1=document.getElementById("ctl00$ContentPlaceHolder1$address1");
    var street2=document.getElementById("ctl00$ContentPlaceHolder1$address2");
    var town=document.getElementById("ctl00$ContentPlaceHolder1$town");
    var county=document.getElementById("ctl00$ContentPlaceHolder1$county");
    var postcode=document.getElementById("ctl00$ContentPlaceHolder1$postcode");
    var country=document.getElementById("ctl00$ContentPlaceHolder1$country");
    var phone1=document.getElementById("ctl00$ContentPlaceHolder1$phone1");
    var phone2=document.getElementById("ctl00_ContentPlaceHolder1_reqphone2");
    var email=document.getElementById("ctl00$ContentPlaceHolder1$email");
    var reemail=document.getElementById("ctl00$ContentPlaceHolder1$reemail");
    var password=document.getElementById("ctl00$ContentPlaceHolder1$psw");
    
    
    var keywords=document.getElementById("ctl00$ContentPlaceHolder1$keywords");
    var info1=document.getElementById("ctl00$ContentPlaceHolder1$info1");
    var info2=document.getElementById("ctl00$ContentPlaceHolder1$info2");
    
    
    if(trimString(fname.value)=="")
    {
        alert("First name is a mandatory field - please complete");
        fname.focus;
        return false;
    }
    
    if(trimString(lname.vlaue)=="")
    {
        alert("Last name is a mandatory field - please complete");
        lname.focus;
        return false;
    }
    else if(trimString(lname.vlaue).length < 2 )
    {
        alert("Last name is invalid");
        lname.focus;
        return false;
    }
    
    if(trimString(company.value)=="")
    {
        alert("Company name is a mandatory field - please complete");
        company.focus;
        return false;
    }
    else if(company.value.indexOf("@")!=-1)
    {
        alert("Company name is invalid - @ is not allowed");
        company.focus;
        return false;
    }
    else if(company.value.indexOf("www")!=-1)
    {
        alert("Company name is invalid - www is not allowed");
        company.focus;
        return false;
    }
    else if(company.value.indexOf("com")!=-1)
    {
        alert("Company name is invalid - com is not allowed");
        company.focus;
        return false;
    }
    else if(company.value.indexOf("co.uk")!=-1)
    {
        alert("Company name is invalid - co.uk is not allowed");
        company.focus;
        return false;
    }
    else if(company.value.indexOf("info")!=-1)
    {
        alert("Company name is invalid - info is not allowed");
        company.focus;
        return false;
    }
    else if(company.value.indexOf("biz")!=-1)
    {
        alert("Company name is invalid - biz is not allowed");
        company.focus;
        return false;
    }
    
    if(trimString(street1.value)=="")
    {
        alert("Street address line1 is mandatory - please complete");
        street1.focus;
        return false;
    }
    else if(trimString(street1.value).length < 2)
    {
        alert("Street address line1 is invalid - please enter atleast two characters");
        street1.focus;
        return false;
    }
    else if(street1.value.indexOf("@")!=-1)
    {
        alert("Street address line1 is invalid - @ is not allowed");
        street1.focus;
        return false;
    }
    else if(street1.value.indexOf("www")!=-1)
    {
        alert("Street address line1 is invalid - www is not allowed");
        street1.focus;
        return false;
    }
    else if(street1.value.indexOf("com")!=-1)
    {
        alert("Street address line1 is invalid - com is not allowed");
        street1.focus;
        return false;
    }
    else if(street1.value.indexOf("co.uk")!=-1)
    {
        alert("Street address line1 is invalid - co.uk is not allowed");
        street1.focus;
        return false;
    }
    else if(street1.value.indexOf("info")!=-1)
    {
        alert("Street address line1 is invalid - info is not allowed");
        street1.focus;
        return false;
    }
    else if(street1.value.indexOf("biz")!=-1)
    {
        alert("Street address line1 is invalid - biz is not allowed");
        street1.focus;
        return false;
    }
    
    if(trimString(street2.value)!="")
    {
        if(street2.value.indexOf("@")!=-1)
        {
            alert("Street address line2 is invalid - @ is not allowed");
            street2.focus;
            return false;
        }
        if(street2.value.indexOf("www")!=-1)
        {
            alert("Street address line2 is invalid - www is not allowed");
            street2.focus;
            return false;
        }
        if(street2.value.indexOf("com")!=-1)
        {
            alert("Street address line2 is invalid - com is not allowed");
            street2.focus;
            return false;
        }
        if(street2.value.indexOf("co.uk")!=-1)
        {
            alert("Street address line2 is invalid - co.uk is not allowed");
            street2.focus;
            return false;
        }
        if(street2.value.indexOf("info")!=-1)
        {
            alert("Street address line2 is invalid - info is not allowed");
            street2.focus;
            return false;
        }
        if(street2.value.indexOf("biz")!=-1)
        {
            alert("Street address line2 is invalid - biz is not allowed");
            street2.focus;
            return false;
        }
    }
    
    if(trimString(town.value)=="")
    {
        alert("Town / City is mandatory - please complete");
        town.focus;
        return false;
    }
    if(trimString(county.value)=="")
    {
        alert("County is mandatory - please complete");
        county.focus;
        return false;
    }
    if(trimString(postcode.value)=="")
    {
        alert("Postcode is mandatory - please complete");
        postcode.focus;
        return false;
    }
    else
    {
        if(postcode.value.indexOf("@")!=-1)
        {
            alert("Postcode is invalid - @ is not allowed");
            postcode.focus;
            return false;
        }
        
        if(postcode.value.indexOf("www")!=-1)
        {
            alert("Postcode is invalid - www is not allowed");
            postcode.focus;
            return false;
        }
        
        if(postcode.value.indexOf(".com")!=-1)
        {
            alert("Postcode is invalid - .com is not allowed");
            postcode.focus;
            return false;
        }
        
        if(postcode.value.indexOf(".co.uk")!=-1)
        {
            alert("Postcode is invalid - .co.uk is not allowed");
            postcode.focus;
            return false;
        }
        
        if(postcode.value.indexOf(".info")!=-1)
        {
            alert("Postcode is invalid - .info is not allowed");
            postcode.focus;
            return false;
        }
        
        if(postcode.value.indexOf(".biz")!=-1)
        {
            alert("Postcode is invalid - .biz is not allowed");
            postcode.focus;
            return false;
        }
    }

    if(trimString(country.value)=="")
    {
        alert("Country is mandatory - please complete");
        country.focus;
        return false;
    }
    
    if(trimString(phone2.value)=="")
    {
        alert("Phone number is mandatory - please complete");
        phone2.focus;
        return false;
    }
    else
    {
    
    
    }
    
    if(trimString(email.value)=="")
    {
        alert("Email address is mandatory - please complete");
        email.focus;
        return false;
    }
    else
    {
        if(email.value.indexOf(" " )!=-1)
        {
            alert("Email address is invalid - no space is allowed");
            email.focus;
            return false;
        }
    }
    
    if(trimString(reemail.value)=="")
    {
        alert("Re enter email address is mandatory - please complete");
        email.focus;
        return false;
    }
    else
    {
        if(reemail.value.indexOf(" " )!=-1)
        {
            alert("Re enter email address is invalid - no space is allowed");
            email.focus;
            return false;
        }
        
        if(reemail.value!=email.value)
        {
            alert("Re enter email address is invalid - must match email address field");
            reemail.focus;
            return false;
        }
    }
    
    if(password.value=="")
    {
    
    
    
    return true;

}

    */
    
    
    
    