Support » Plugins » embedding javascript in a post

  • Hi there,

    Has anybody ever managed to embed some javascript from in a wordpress post?

    I’ve tried several times but it doesn’t work and I can’t seem to find a plug in that could help me. I am trying to embed the following:

    <script>(function() {
    var d = document, fr = d.createElement(‘script’); fr.type = ‘text/javascript’; fr.async = true;
    fr.src = ((d.location.protocol.indexOf(‘https’) == 0)? ‘https://s-‘ : ‘http://’) + ‘’;
    var s = d.getElementsByTagName(‘script’)[0]; s.parentNode.insertBefore(fr, s);

    I know nothing about javascript, so if anybody could write a solution for dummies I would be wordpressly grateful!

    Thank you!

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘embedding javascript in a post’ is closed to new replies.