This looks like a mixture of PHP and javascript. PHP can't execute Javascript and vice versa. If you enclose the javascript in script tags and echo it as a string It will probably get you what you want. But this should be handled by the template.
↧