This will resolve your problems - passing the parameter via data attribute:
http://forum.shopware.com/discussion/17770/smarty-variable-in-javascript
This will resolve your problems - passing the parameter via data attribute:
http://forum.shopware.com/discussion/17770/smarty-variable-in-javascript