- Joined
- Sep 10, 2006
- Messages
- 2,811
- Reaction score
- 1,417
PHP:
$.global = {
dayBox_0: ""
}
function addInput(dayWrap) {
$("."+dayWrap+" .menuText.last").keyup(function() {
alert($.global.dayWrap);
});
}
$(document).ready(function(){
addInput('dayBox_0');
});
You should see what's I want to archieve from the code anyway,
this way it takes $.global.dayWrap "dayWrap" as just another variables that should've been defined in my $.global namespace, but I need it to consider "dayWrap" as the variables defined in function, thus becaming $.global.dayBox_0.. Any idea how to do that?

