JQuery - Code Example
$(document).ready(function() {


$("a").click(function(event) {
alert("Thanks for visiting!");

/* Hover on/off element */
$("#selector").hover(function() {
}, function() {


/* Below is a brief overview of some of the most commonly used selectors. */

$("*") - Wildcard: /* selects every element on the page. */
$(this) - Current: /* selects the current element being operated on within a function. */
$("p") - Tag: /* selects every instance of the <p> tag. */
$(".example") - Class: /* selects every element that has the example class applied to it. */
$("#example") - Id: /* selects a single instance of the unique example id. */
$("[type='text']") - Attribute: /* selects any element with text applied to the type attribute. */
$("p:first-of-type") - Pseudo Element: /* selects the first <p>. */

Posted in:

GnasheR's Snippets

PHP as it's known today is actually the successor to a product named PHP/FI. Created in 1994 by Rasmus Lerdorf, the very first incarnation of PHP was a simple set of Common Gateway Interface (CGI) binaries written in the C programming language. Originally used for tracking visits to his online resume, he named the suite of scripts "Personal Home Page Tools," more frequently referenced as "PHP Tools." Over time, more functionality was desired, and Rasmus rewrote PHP Tools, producing a much larger and richer implementation. This new model was capable of database interaction and more, providing a framework upon which users could develop simple dynamic web applications such as guestbooks. In June of 1995, Rasmus released the source code for PHP Tools to the public, which allowed developers to use it as they saw fit. This also permitted and encouraged users to provide fixes for bugs in the code, and to generally improve upon it.
Go To Top