I have replied to the other post. But the example is strange. The META keyword is for robots and they will not run any server side script and will not see your dynamically generated keywords. Or do you need to hide your keywords from competition. They can just check the javascript code and read them there. Not to mention that META keywords are ignored by Google.
webdesign