title: Jquery display text from mysql
body: <p>Maybe someone can give me a little help.
  I modified a jquery to appear as i wanted, you can see it here: <a href="http://loja.genesiseries.com/depoimentos/index.html" rel="nofollow">http://loja.genesiseries.com/depoimentos/index.html</a></p>
  
  <p>But i need display text from mysql DB, so i created a new page and put php echo.
  <a href="http://loja.genesiseries.com/depoimentos/mysql.php" rel="nofollow">http://loja.genesiseries.com/depoimentos/mysql.php</a></p>
  
  <p>It work, but not as i wanted.
  <strong>What i need</strong>: When the visitor click in proximo (NEXT) button the jquery show the next div with a new text from database
  <strong>What is happening</strong>: When i click in proximo (NEXT) button the jquery shows the next div but don't load a new text, how to fix it?</p>
  
  <p>I was wondering now and maybe is a good improvement remove the previous button (anterior) since the button will load a random text, doesn't make sense back to it, or do? i'm also thinking about the div limit, here i just put 3 DIVS, <strong>when I get it at the end of divs the jquery shows first div again, how to fix it</strong>?</p>
  
  <p>I know absolutely nothing about jquery.</p>
  
  <p>Here is the php code:</p>
  
  <pre><code>&lt;?php
  $sql = "SELECT * FROM opinions ORDER BY rand() LIMIT 5";
  $resultado = mysql_query($sql);
  while ($linha=mysql_fetch_array($resultado)) {
  $depoimento = $linha["depoimento"];
  $client = $linha["client"];
  
  }
  ?&gt;
  </code></pre>
  
  <p>Now the divs</p>
  
  <pre><code>&lt;div id="slides"&gt;
      &lt;div class="slides_container"&gt;
  
          &lt;div&gt;
              &lt;p class="depoimento"&gt;&lt;font color="#bdbdbd"&gt;&lt;?php echo "$depoimento"; ?&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="cliente"&gt;&lt;font color="#99CB1E"&gt;&lt;?php echo "$client"; ?&gt;&lt;/font&gt;&lt;/p&gt;
          &lt;/div&gt; 
          &lt;div&gt;
              &lt;p class="depoimento"&gt;&lt;font color="#bdbdbd"&gt;&lt;?php echo "$depoimento"; ?&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="cliente"&gt;&lt;font color="#99CB1E"&gt;&lt;?php echo "$client"; ?&gt;&lt;/font&gt;&lt;/p&gt;
          &lt;/div&gt;
  
     &lt;div&gt;
  &lt;p&gt;&lt;font color="#bdbdbd"&gt;Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed                 do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,         quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.&lt;/font&gt;    &lt;/p&gt;
  &lt;/div&gt;
  
      &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Help?
  Thanks a lot!</p>