Jquery in page?
-
How can i get this to work in a page?
<!DOCTYPE html> <html> <head> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script> <script> jQuery(document).ready(function($) { $("a").click(function(){ $('#versie').text('Welkom '+ $(this).attr('data-name')); }); }); </script> </head> <body> <div id="div1"><h2>Selecteer de gewenste versie: <span id="versie"></span></h2></div> <a href="#" data-name="2007">2007</a> | <a data-name="2010" href="#">2010</a> | <a data-name="2013" href="#">2013</a> </body> </html>you can test the code in: http://www.w3schools.com/jquery/tryit.asp?filename=tryjquery_event_ready
-
Hi, your are in the wrong forum.
This forum is only for blogs/sites hosted by WordPress.comWordPress.COM and WordPress.ORG are completely separate and different http://support.wordpress.com/com-vs-org/
And you should ask in the WordPress.org forum.
http://wordpress.org/support/
- The topic ‘Jquery in page?’ is closed to new replies.