1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Studiopress and Javascript

Discussion in 'Blogging' started by lizmoz, Sep 4, 2009.

  1. lizmoz

    lizmoz Power Member

    Joined:
    Oct 10, 2008
    Messages:
    560
    Likes Received:
    328
    Hey,
    anyone got aclue why javascript code won't run in text widgets or dedicated plugin widgets either in studiopress theme lifestyle?

    Spent the whole night trying to embed a nice banner rotator there.. it's in js. Works perfectly with e.g. the default theme. Wordpress support forums claim this to be a feature of the newest wp that it won't allow loading js scriptf from other than the blog's own js folder but this isn't true as I have tested it with a brand new installation on another domain and it just works..

    Any ideas why can't get js running with this theme? Also just embedding it directly to a post with any embed plugins - no show.

    Really need this rotator there..Anyone?

    cheers,
    lizmoz
     
  2. gimme4free

    gimme4free Executive VIP Jr. VIP Premium Member

    Joined:
    Oct 22, 2008
    Messages:
    1,879
    Likes Received:
    1,932
    Text widgets are for text only? I know you can get a PHP widget plugin that it should work in.

    Edit: Apparently javascript does work in text widgets, maybe it's a problem with your code?

    Here is the PHP widget plugin if you was looking for it anyway:
    http://wordpress.org/extend/plugins/php-code-widget/
     
  3. lizmoz

    lizmoz Power Member

    Joined:
    Oct 10, 2008
    Messages:
    560
    Likes Received:
    328
    Nah, text widgets run js too. And I tried php widget plugin (the one that is supposed to be ok with flash etc too) but didn't help. Tried all the js embedding widgets too. Something more fishy with this theme going on I guess.
     
  4. cybernox

    cybernox Newbie

    Joined:
    Mar 30, 2008
    Messages:
    47
    Likes Received:
    7
    I think it works. Lifestyle theme is simple theme .. you can edit and hard code your js in there.
     
  5. lizmoz

    lizmoz Power Member

    Joined:
    Oct 10, 2008
    Messages:
    560
    Likes Received:
    328
    Yea I have absolutely no idea why it doesn't work.. should work from normal widgets as well..even see the right stuff in the page source but just shows blank where it should show my rotator which works on other wps of mine... ffffffffuuuuuuuuuuuu
     
  6. gimme4free

    gimme4free Executive VIP Jr. VIP Premium Member

    Joined:
    Oct 22, 2008
    Messages:
    1,879
    Likes Received:
    1,932
    Is your rotator code working by itself?
     
  7. shadowpwner

    shadowpwner Regular Member

    Joined:
    Apr 19, 2009
    Messages:
    300
    Likes Received:
    73
  8. lizmoz

    lizmoz Power Member

    Joined:
    Oct 10, 2008
    Messages:
    560
    Likes Received:
    328
    Ok. Did my homeworks on the above tips, still couldn't figure it out. But this neat plugin did the job for me with a bit of extra work:
    Code:
    http://wordpress.org/extend/plugins/datafeedr-ads/
    Just a tip!