Explorar o código

Listing 6.3: $.loadJSON().

Frederic G. MARAND %!s(int64=9) %!d(string=hai) anos
pai
achega
c114f16a58
Modificáronse 1 ficheiros con 5 adicións e 0 borrados
  1. 5 0
      Chapter 6/06.js

+ 5 - 0
Chapter 6/06.js

@@ -6,4 +6,9 @@ $(document).ready(function () {
     $('#dictionary').load('a.html');
     alert('Loaded');
   });
+
+  $('#letter-b a').click(function (event) {
+    event.preventDefault();
+    $.getJSON('b.json');
+  });
 });