Hi, I have two images, one looks like the up arrow button of a vertical scrollbar and the other looking like the down arrow button of a vertical scrollbar.

I want that when an user clicks on the up arrow button the contents of a table to scroll up and when the down arrow button is clicked the contents of the table to go down.

Please help!!!!!!!!!
Thanks in advance

11 Years
Discussion Span
Last Post by Fungus1487

do you want the contents to move one click at a time or similiar to a scroll bar. if a scrollbar. why not use a <div style="overflow:scroll;"></div>

im guessing you could do an

  <script language='javascript'>
    function move(amount) {
      val margin = document.getElementById('content').style.marginTop();
      amount = parseFloat(margin) + amount;
      document.getElementById('content').style.marginTop= amount.toString() + 'px';
  <p><a href="#" onclick="move(5)"><img src="up"></a>
  <a href="#" onclick="move(-5)"><img src="up"></a></p>

      <td id="content"><p>blah blah</p></td>

this is untested so i dunno but i rekon thats a basis of what you should do.

hope it helps

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.