-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating
CouchDB and PHP Web Development Beginner's Guide
By :
Because of the influx of people using jQuery, Google has set up a content delivery network that serves up the jQuery library for us without anything being required in our project. Let's tell our layout.php file where to find jQuery.
Open the layout.php file, and add the following code right before the end of the body section:
<script type="text/javascript" src= "//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"> </script> </body> </html>
We just added one line of code before the end of our body tag in the layout.php file. That's all it took to use jQuery with our project! You may be wondering why we decided to put our jQuery library all the way at the bottom of our file. The simplest explanation is that as a browser loads code, it does so one line at a time. By putting JavaScript at the bottom of the page, it allows the other elements, such as CSS and HTML markup, to load faster, giving the...
Change the font size
Change margin width
Change background colour