| 1 | <html> |
|---|
| 2 | <head> |
|---|
| 3 | |
|---|
| 4 | <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.min.js"></script> |
|---|
| 5 | |
|---|
| 6 | <script type="text/javascript"> |
|---|
| 7 | $(document).ready(function(){ |
|---|
| 8 | $("#test").load("jq-ajax-test.html"); |
|---|
| 9 | }); |
|---|
| 10 | </script> |
|---|
| 11 | |
|---|
| 12 | <script type="not/javascript"> |
|---|
| 13 | alert("not fired"); // but fired from in jq-ajax-test |
|---|
| 14 | </script> |
|---|
| 15 | |
|---|
| 16 | </head> |
|---|
| 17 | <body class="tundra"> |
|---|
| 18 | <p>You should see: "expected", "should not be executed". if you see "not fired", something else is wrong</p> |
|---|
| 19 | <div id="test"></div> |
|---|
| 20 | </body> |
|---|
| 21 | </html> |
|---|
| 22 | |
|---|
| 23 | --[snip:jq-ajax-test.html]-- |
|---|
| 24 | <div class="bar"> |
|---|
| 25 | <script type="text/javascript"> |
|---|
| 26 | alert('expected'); |
|---|
| 27 | </script> |
|---|
| 28 | <script type="not/javascript"> |
|---|
| 29 | alert("should not be executed, but is"); |
|---|
| 30 | </script> |
|---|
| 31 | </div> |
|---|
| 32 | |
|---|
| 33 | |
|---|
| 34 | |
|---|