Hi Vishan,
What are you trying to achieve? Looking at your post again, you are referencing the newitem page which one normally wouldn't call with an ID as it's designed to create a new id when a new item is created. (I could understand the editform being called this way).
Anyway, basically if you want to run inline code, you'll need to make some alterations to your setup to allow it. A past colleague of mine posted a blog about this a while ago (PageParserPaths) http://geekswithblogs.net/sevans/Default.aspx
Then once you've done that it would be a matter of adding a script block to the ASPX page with the code above, it it.
Cheers,
Paul.
Paul Leigh