Need help? Check out our Support site, then


Javascript in Text Widgets

  1. I tried adding the code for StatCounter into a text widget, but when I do, it kills off some of the lines in the code (especially the ones that say "<script type="text/javascript" language="javascript">") meaning the code itself displays on my sidebar, rather than just the image-button.
    Is there a reason these lines are being removed, and is there a way around it? Becaue I'd like to the better detailed stat reports available from Statcounter, but I like WordPress.

  2. Javascript/flash/iframes are stripped out for security.

  3. Katm, so this means that the Statcounter code can't be installed?

  4. a search! do a search!
    zillion people asked the same before.
    use the faq!
    do a search!

    sorry for the ranting. but i'm rather new in here, and it's already making me tired, i can't even imagine volunteers and wordpress older users!

  5. @aurelius...

    Unless there is a plain html version (and even I think some tags are stripped out) then no, you can't use it.

    If you post a link to the site you want to use, then someone can take a look at it and see if there are any other options other than the java-script one.

    [edit]
    See this FAQ: http://faq.wordpress.com/2006/05/20/how-do-i-add-a-counter-using-a-widget/
    [/edit]

  6. Javascripts are removed due to security concerns. The faq blog linked at teh top of the forums as three examples of what can be done with javascripts on a shared environment such as this one.

    And, yes, a search would have found you the answer as well. ;)

Topic Closed

This topic has been closed to new replies.

About this Topic