Note that there are some explanatory texts on larger screens.

plurals
  1. POMake permanent position of arrow with CSS without affect text alignment from table cell
    text
    copied!<p>I have an HTML table like:</p> <pre><code>&lt;div&gt; &lt;table border="1"&gt; &lt;thead&gt; &lt;tr class="example"&gt; &lt;th&gt; &lt;span id="item1"&gt; &lt;span&gt;Value1&lt;/span&gt; &lt;span class="sort-up no-display"&gt;&amp;nbsp;&lt;/span&gt; &lt;/span&gt; &lt;/th&gt; &lt;th&gt; &lt;span id="item2"&gt; &lt;span&gt;Value2&lt;/span&gt; &lt;span class="sort-up no-display"&gt;&amp;nbsp;&lt;/span&gt; &lt;/span&gt; &lt;/th&gt; &lt;/tr&gt; &lt;/thead&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt;Example 1&lt;/td&gt; &lt;td&gt;Example 2&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;Example 3&lt;/td&gt; &lt;td&gt;Example 4&lt;/td&gt; &lt;/tr&gt; &lt;/tbody&gt; &lt;/table&gt; &lt;/div&gt; </code></pre> <p>in header, I have an hidden up arrow which appears when at mouseover/mouseout with jquery</p> <pre><code>&lt;script type="text/javascript"&gt; $(function(){ $(".example th").on("mouseover mouseout", function(){ var $sort_up = $(this).children().find("span").first().next(); $sort_up.toggleClass("no-display"); }); }); &lt;/script&gt; </code></pre> <p>where <code>no-display</code> is <code>display:none</code> css.</p> <p>The screenshots (before)</p> <p><img src="https://i.stack.imgur.com/Vvyd0.png" alt="enter image description here"></p> <p>And after:</p> <p><img src="https://i.stack.imgur.com/3ShDg.png" alt="enter image description here"></p> <p>I want that header title to not be moved at mouseover/mouseout event.</p> <p>How to do that ? Maybe is a CSS trick.</p> <p>PS: Maybe like:</p> <p><img src="https://i.stack.imgur.com/X0feV.png" alt="enter image description here"></p> <p>Thanks for your patience with me that I have no more knowledge in CSS.</p>
 

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