jQuery reduce the width from left to right
<p>Hello I have a DIV that has a width of 500px.</p>

<p>I am trying to reduce the width with an animation from 500px to 0px and from 0px to 500px again.</p>

<p>There is only a problem, that the DIV is reduced starting from the right to the left.</p>

<p>I want the opposite thing.</p>

<p>From the start the width will be reduced and animated from left to right, and then will be increased from 0px to 500px starting from right to left.</p>

<p>How can I do it with jQuery?</p>

<p>Thanks for any help</p>

<p><strong>EDITED</strong></p>

<pre><code>function animateText(px) {
  $('#slidetext').animate({
   'width' : px
  });
 }
</code></pre>
