Skip to main content

Bug Tracker

Side navigation

Ticket #2169: testcase.html
File testcase.html, 1.0 KB (added by ieure, January 15, 2008 09:18PM UTC)

Testcase. 1.2.1 & 1.2.1 work in Firefox; 1.2.1 works in IE; 1.2.2 breaks in IE.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
          "http://www.w3.org/TR/html4/strict.dtd">
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
        <meta name="author" content="Ian Eure <ieure@socialplatform.com>">
        <title>jQuery clone() testcase</title>
<!--
        <script type="text/javascript" src="jquery-1.2.1.pack.js"></script>
-->
        <script type="text/javascript" src="jquery-1.2.2.pack.js"></script>
    </head>
    <body>
        <button>Test</button>

        <h3>Divs</h3>
        <div class="test">Test</div>
        <div class="final">Final</div>


        <h3>Table</h3>
        <table>
          <tr class="test"><td>Test</td></tr>
          <tr class="final"><td>Final</td></tr>
        </table>
        <script type="text/javascript">
            $('button').click(function()
            {
                $('div.test:eq(0)').clone().insertBefore('div.final');
                $('tr.test:eq(0)').clone().insertBefore('tr.final');
            });
        </script>
    </body>
</html>

Download in other formats:

Original Format