www.webdeveloper.com
Results 1 to 2 of 2

Thread: Animate new table rows

Hybrid View

  1. #1
    Join Date
    Jun 2008
    Location
    London
    Posts
    175

    Animate new table rows

    Hi all, I've got a table in a while loop saved as table.php

    PHP Code:
    <?php do { ?>
      <table width="176" border="1">
        <tr>
          <td width="166"><label for="textfield"></label>
      <input name="textfield" type="text" id="textfield" value="<?php echo $row_Recordset1['comment']; ?>"></td>
        </tr>
      </table>
      <?php } while ($row_Recordset1 mysql_fetch_assoc($Recordset1)); ?>
    In my main index.php, I call the table into <div id="table"> using jquery, and update the table data every second

    HTML Code:
    <script type="text/javascript">
        $(document).ready(function(){
          refreshTable();
        });
    
        function refreshTable(){
            $('#table').load('table.php');
            setTimeout(refreshTable, 1000);
        }
    </script>
    I need to get the new table rows to animate down rather than just appear, if there is new data when it refreshes. Can anyone help me do this and do I need the while loop in a DIV rather than table? Thanks

  2. #2
    Join Date
    Mar 2009
    Posts
    452

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles