Embedding javascript on a page

This is an open forum for any mojoPortal topics that don't fall into the other categories.

This thread is closed to new posts. You must sign in to post in the forums.
3/23/2009 5:40:35 PM
Gravatar
Total Posts 64
Gerry Roston gerry (at) pairofdocs (dot) net

Embedding javascript on a page

All,

I would like to make use of the javascript code found here, hivelogic.com/enkoder/form, to protect my email address. I found a previous forum posting in which Joe recommends using this.Page.ClientScript.RegisterClientScriptBlock. I tried this, but I must have done something wrong. Basically, I edited the HTML content, selected source view, and pasted in the javascript. (Yes, first I concatenated the multiple lines to get rid of the extra quotation marks.) However, once I switched back to the regular view, all I saw was some text with the first line of the script. Please help.

3/24/2009 12:29:13 PM
Gravatar
Total Posts 18439

Re: Embedding javascript on a page

You should be able to paste that in in html source view. I think the mistake you made was

 first I concatenated the multiple lines to get rid of the extra quotation marks

just paste exactly what they gave you, don't second guess them, it worked for me.

Note that it won't work in the forums or in the blog coments where we protect from javascript but it does work in html content and blog posts.

Hope it helps,

Joe

3/24/2009 10:41:13 PM
Gravatar
Total Posts 64
Gerry Roston gerry (at) pairofdocs (dot) net

Re: Embedding javascript on a page

Joe,

Thought too much - just drop the javascript, as is, nothign else, and it works fine. Thx.

You must sign in to post in the forums. This thread is closed to new posts.