JohnandSwifty
Technical User
Hi,
I have read just about every post and article regarding this but for some reason im just not getting it right! arg
Can someone help me with the below:
I have an objects that store application settings across the modules in my application - for example - app.moduleName.contentName.settingName
i need to set these variables dynamically - so i pass a function moduleName, contentName and then the function performs whatever and then sets the relevant variable accordingly.
So what im trying to do is -
'app.' + moduleName + '.' + contentName + '.' + 'settingName' = settingName
And my attempt is -
var varName = 'app.' + moduleName + '.' + contentName + '.settingName';
window[varName] = value;
thanks
I have read just about every post and article regarding this but for some reason im just not getting it right! arg
Can someone help me with the below:
I have an objects that store application settings across the modules in my application - for example - app.moduleName.contentName.settingName
i need to set these variables dynamically - so i pass a function moduleName, contentName and then the function performs whatever and then sets the relevant variable accordingly.
So what im trying to do is -
'app.' + moduleName + '.' + contentName + '.' + 'settingName' = settingName
And my attempt is -
var varName = 'app.' + moduleName + '.' + contentName + '.settingName';
window[varName] = value;
thanks