Read Resource File Entry In Javascript - MVC Application
I am working on a MVC application and I need to read resource file and get values , pass them in a javascript file. For this I am just calling a js function written in separate js
Solution 1:
You need a comma in your return object for setvalues. It's still not going to work, but at least that fixes your syntax error.
return {
getMess: function(){ return value1;},
getLab: function() { return value2;}
}
Also, it seems kind of odd returning the value1 and value2 in setvalue()
, could I suggest returning the values in the getter? Fixed and refactored in this Fiddle
Post a Comment for "Read Resource File Entry In Javascript - MVC Application"