I want to create a function that gets a global variable as a parameter and changes it after a timeout.
function change(variable, value, time)
{
setTimeout(function() { variable= value; }, time);
}
I do not know what variable is in advance.
problem is when I do this the assignment doesn't hold for outside the function.
How can I tell the function that var is global?