
// Remove Scroll Bar
document.write('<script type="text/javascript" src="http://js.locatorsearch.com/iframe.js"></script>');

document.domain = 'statebank1898.com';


// JavaScript Document
var searchString = document.location.search;
var iFrameUrl ='' ;
var street = '' ;
var city = '' ;
var state = '' ;
var zipcode = '' ;

var ShowAllBranch = false ;

// strip off the leading '?'
searchString = searchString.substring(1);

var nvPairs = searchString.split("&");

for (i = 0; i < nvPairs.length; i++)
{
     var nvPair = nvPairs[i].split("=");
     var name = nvPair[0];
     var value = nvPair[1];	 
	 
	 if (nvPair[0] == "ShowAllBranch")
	 {
		ShowAllBranch = true ;
	 }
	 if (nvPair[0] == "zipcode")
	 {
		iFrameUrl = iFrameUrl + '&zipcode=' +  nvPair[1] ;	 
	 }
}

if (ShowAllBranch)
{
	document.write('<iframe id="atmlocator" src="http://locations.statebank1898.com/ListCUServiceCenter.aspx?loc=1" height="1200" onload="DYNIFS.resize(\'atmlocator\')" width="525" name="atmlocator" frameborder="0" allowtransparency="true" scrolling="no">Your browser doesn\'t support iframes</iframe>');
}
else
{
	if (iFrameUrl.length > 0)
	{
		document.write('<iframe id="atmlocator" src="http://locations.statebank1898.com/PostSearch.aspx?' + iFrameUrl + '" height="1200" onload="DYNIFS.resize(\'atmlocator\')" width="525" name="atmlocator" frameborder="0" allowtransparency="true" scrolling="no">Your browser doesn\'t support iframes</iframe>');
	}
	else
	{
		document.write('<iframe id="atmlocator" src="http://locations.statebank1898.com/index.aspx" height="1200" onload="DYNIFS.resize(\'atmlocator\')" width="525" name="atmlocator" frameborder="0" allowtransparency="true" scrolling="no">Your browser doesn\'t support iframes</iframe>');
	}
}


 



