Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>If you consider the "Cascading Order" of css, could you not just add a css style at the very end of all your previous css definition in order to cancel any css effect you currently have for tooltip effect ?</p> <p>That css rule would only be declared if Javascript is activated and JQuery detected.</p> <p>That way, you are sure your <a href="http://psacake.com/web/jl.asp" rel="nofollow noreferrer">css tooltip effect</a> is not in conflict with your JQuery effect.</p> <p>Something like:</p> <pre><code>a.info:hover span{ display:none} </code></pre> <p>with the use of "js_enabled" class to make this css rule conditional.</p> <p>You also can do it by <a href="http://forum.mootools.net/viewtopic.php?id=6635" rel="nofollow noreferrer">adding css rule on the fly</a>:</p> <pre><code>function createCSSRule(rule,attributes) { //Create the CSS rule var newRule = "\n"+rule+"{\n"; for (var attribute in attributes) { newRule += "\t" + attribute + ": " + attributes[attribute] + ";\n"; } newRule += "}\n"; //Inject it in the style element or create a new one if it doesn't exist styleTag = $E('style[type="text/css"]') || new Element("style").setProperty('type','text/css').injectInside(document.head); if(window.ie) { styleTag.styleSheet.cssText += newRule; } else { styleTag.appendText(newRule); } } </code></pre> <hr> <p>The most simple solution for <a href="http://www.onlinetools.org/articles/unobtrusivejavascript/cssjsseparation.html" rel="nofollow noreferrer">Separation of CSS and Javascrip</a> is to <strong>remove your css class</strong></p> <pre><code>function jscss(a,o,c1,c2) { switch (a){ case 'swap': o.className=!jscss('check',o,c1)?o.className.replace(c2,c1): &lt;- o.className.replace(c1,c2); break; case 'add': if(!jscss('check',o,c1)){o.className+=o.className?' '+c1:c1;} break; case 'remove': var rep=o.className.match(' '+c1)?' '+c1:c1; o.className=o.className.replace(rep,''); break; case 'check': return new RegExp('\\b'+c1+'\\b').test(o.className) break; } } </code></pre> <p>This example function takes four parameters:</p> <p><code>a</code><br> defines the action you want the function to perform.<br> <code>o</code><br> the object in question.<br> <code>c1</code><br> the name of the first class<br> <code>c2</code><br> the name of the second class </p> <p>Possible actions are:</p> <p><code>swap</code><br> replaces class c1 with class c2 in object o.<br> <code>add</code><br> adds class c1 to the object o.<br> <code>remove</code><br> removes class c1 from the object o.<br> <code>check</code><br> test if class c1 is already applied to object o and returns true or false. </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload