Okay basicly I wanna do the following:
Where changetype an changevalue could be anything. Is this possible? possibly using the eval function? the changevalue works fine, just getting it to register the dynamic property is a problem.
My last resort will be a switch/case statement, but I would much rather a sigle/few lines of code.
Thanks, Josh
Code:
var changetype = "backgroundColor"; changevalue = "red"; element.style.changetype = changevalue;
My last resort will be a switch/case statement, but I would much rather a sigle/few lines of code.
Thanks, Josh
Comment