开发者

Override css rendered by an advertising javascript

I have a javascript code which loads some advertising code:

<script type="text/javascript" language="javascript" charset="utf-8" src="http://adspaces/103872.js"></script>

In my browser here is how my code renders:

<div id="content0" class="content" title="www.site.com" valign="middle">

    <div style="font-size: 12.08px; 开发者_JAVA技巧line-height: 14.08px;" class="title" id="title0">

        <a class="link" id="" href="the link" target="_blank">The anchor</a>

    </div>

   <a class="link" id="" href="the link" target="_blank"><img class="img" id="im_0" src="img src" onerror="swi(this);" onload="if(this.height >43){this.height=43;} formatAd(0);" align="left" border="0" height="43"></a>

   <div class="text" id="text0">

       <a class="link" id="" href="the link" target="_blank">The anchor</a>
       </div>

</div>

How can I override the css rules rendered by the javascrip. I need to put my own text site, line height, etc. Is it possible?

Thank you very much!


You would need to use !important to override the inline styles.

#title0 {
    font-size: 13px !important;
}

jsFiddle.

Or alternatively, modify them with JavaScript.


The only way I can think of is overriding it with JavaScript. You can easily target the elements with jQuery and change their inline CSS.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜