//global variables

var directionMemory

var contentArray = new Array(2)
contentArray [0]="Evans studio works with computer technologies (and other bits and pieces) to create cool web applications and innovative software art. We specialise in interaction design, have a thing about the mobile internet and do a great line in effective web marketing campaigns. Oh and finally, we might be easy going but we design to the latest W3 standards, develop software to ISO 9126, test in accordance with IEEE 829 and work within thorough contractual frameworks.";
contentArray [1]="If you are interested in having us work with you or your organisation contact us via one of the channels given below.";



function drawPic() 
{
var image = document.createElement("img");
   image.setAttribute("src","images/yard.jpg");
   image.setAttribute("alt","The courtyard at Etloe Barn during construction work");
var myContentNode = document.getElementById("rightcol");
var myNode=myContentNode.childNodes[1];
    myContentNode.replaceChild(image,myNode);
var para = document.createElement("p");
    myContentNode.appendChild(para);    
var alink = document.createElement("a");
    alink.setAttribute("href", "index.php");
    alink.setAttribute("title", "go back");
    para.appendChild(alink);
    alink.createTextNode;
alink.appendChild(document.createTextNode("Back"));
}

<!--slightly diff coding as I tried all sorts to work out IE white space bug-->

function writeMore()
{
var newTxt=document.createTextNode(contentArray[0]);
var newTxt2=document.createTextNode(contentArray[1]);
var myContentNode = document.getElementById("rightcol").childNodes[0];
var para = document.createElement("p");
    para.className = "largeFont"; 
    document.getElementById("rightcol").replaceChild(para,myContentNode);
    para.appendChild(newTxt);
var para2 = document.createElement("p");
    para2.className = "largeFont"; 
    document.getElementById("rightcol").appendChild(para2);
    para2.appendChild(newTxt2);
    writeLink();
}

function writeLink()
{
var alink = document.createElement("a");
    alink.setAttribute("href", "index.php");
    alink.setAttribute("title", "go back");
    MyContentNode=document.getElementById("rightcol");
    MyContentNode.appendChild(alink);
    alink.createTextNode;
alink.appendChild(document.createTextNode("Back"));
}

function show_arrow(imageflag2)
{
if (imageflag2=="1") 
{
document.getElementById("popup").style.color="#666";
}
else
{
document.getElementById("popup").style.color="#FFFFFF";
}
}

/* depreciated -rob@pollen-8.co.uk 
function show_summary(imageflag2,myId)
{
if (imageflag2=="1") 
{
document.getElementById(myId).style.visibility="visible";
}
else
{
document.getElementById(myId).style.visibility="hidden";
}
}*/

<!--this opens a new window-->

function open_win(win_URL, myWindowName)
{

	var w = 800;
	var h = 600;
      var t = 50;
      var l = 100;	
	proj = myWindowName;
	arg = "width="+ w +", height="+ h +", top="+ t +",left="+ l +", toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=yes ";	
	

popup= (document.layers) ? window.open(win_URL, proj, arg) : window.open(win_URL, proj, arg);
popup.focus();

}


<!--this closes the window-->

function close_win()

{
window.close();

}

//Panning an image in an html doc with JS

function recordXloc(eventObject)
{
var directionMemory=eventObject.layerX;
}



function animate(ident, eventObject)
{
//first get mouse x and then compare with memory variable to ascertain direction.

var mouseX=eventObject.layerX;
var direction=directionMemory-mouseX;

//then move image to follow mouse

mouseX=mouseX/2.5;
mouseX=parseInt(mouseX);
mouseX=0-mouseX;
myOffSet=mouseX+"px";
document.getElementById("nosepan").style.left=myOffSet;
}


