Note that there are some explanatory texts on larger screens.

plurals
  1. POjquery toggle open all div s on one click
    text
    copied!<p>Please take a look at below codes, for whatever reason I am unable to open one div only when I click on the edit link, it opens all divs when I click the edit link. </p> <p><strong>jQuery</strong></p> <pre><code>$(document).ready(function () { $("input:button[name='uploadboy']").click(function () { $(this).parent().children('.uploadboy').slideToggle(200, 'swing'); }); }); </code></pre> <p><strong>HTML</strong></p> <pre><code>&lt;div style="overflow:auto;" class="links-box "&gt; &lt;p style="float:left; width:250px;" id="links"&gt; &lt;input type="button" name="uploadboy" id="uploadboy" value="Uploaded" title="Uploaded" style="text-decoration:none; color: white; text-shadow:none; background: #0692fe; float:left;" class="g-button"&gt; &lt;/p&gt; &lt;/div&gt; &lt;div class="uploadboy" width: 600px;min-height:50px;background-color: #F2FDD7;border-radius: 10px;border: 1px solid #8EBD43;"&gt; &lt;p&gt;content&lt;/p&gt; &lt;/div&gt; &lt;div style="overflow:auto;" class="links-box "&gt; &lt;p style="float:left; width:250px;" id="links"&gt; &lt;input type="button" name="uploadboy" id="uploadboy" value="Uploaded" title="Uploaded" style="text-decoration:none; color: white; text-shadow:none; background: #0692fe; float:left;" class="g-button"&gt; &lt;/p&gt; &lt;/div&gt; &lt;div class="uploadboy" width: 600px;min-height:50px;background-color: #F2FDD7;border-radius: 10px;border: 1px solid #8EBD43;"&gt; &lt;p&gt;content&lt;/p&gt; &lt;/div&gt; </code></pre> <p><a href="http://jsfiddle.net/YMkZn/" rel="nofollow">example in jsFiddle</a></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