Okay, I'm not sure what this is called, parsing? Recheck variable?... I'll edit title when I know!
Something simple like this;
var a = b;
var c = d;
var bd = 'hello!';
var e = a + c;
alert(e);
// Want to alert 'Hello!'
In my actual script var b is set on a click event which makes var c equal something like this Staff_Member_TimMarshall
whereas a = Staff_Member_
and the onclick sets b = TimMarshall