Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 2. Foundation JavaScript > Adding JavaScript to an HTML page

2.3. Adding JavaScript to an HTML page

You should now have an idea of what jQuery is and why you're using it, so let's put everything together and construct a basic HTML page with a bit of JavaScript goodness.

<!DOCTYPE html>

<html>
        <head>
                <title>Adding JavaScript to a HTML page</title>
                <meta charset="utf-8">

                <!-- CSS to go here -->

                <script type="text/javascript" src="http://ajax.googleapis.com
/ajax/libs/jquery/1/jquery.min.js"></script> <script type="text/javascript"> $(document).ready(function() {


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free 10-Day Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint