Skip to content

Instantly share code, notes, and snippets.

@jonahlyn
jonahlyn / gist:282053
Created January 20, 2010 17:59
Test loading a gist into jsbin. http://jsbin.com/gist/282053
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<script class="jsbin" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"></meta>
<style type="text/css">
#system-message {
background-color: rgb(254, 255, 170);
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
<html>
<head>
<meta charset=utf-8 />
<title>Ugly Announcements</title>
</head>
<body>
<div style="font-size: 12px;">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
<html>
<head>
<meta charset=utf-8 />
<title>Better Announcements</title>
<style>
ul.announcements {
padding: 0;
}
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>Simple Slider Plugin</title>
<style type="text/css">
ul.simple-slider {
padding: 0.5em 0;
margin: 0;
}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Tool-Tip Experiment with Definition List</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<style type="text/css">
body { font: 16px "Lucida Grande",Helvetica,Verdana,Arial,Tahoma,sans-serif; }
#tip {
@jonahlyn
jonahlyn / definitions.html
Created April 15, 2010 19:49
A definition list styled like a table. http://jsbin.com/gist/367558
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Definitions</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<style type="text/css">
body { font: 16px "Lucida Grande",Helvetica,Verdana,Arial,Tahoma,sans-serif; }
dl { color: #444;
@jonahlyn
jonahlyn / cookieTesting.html
Created May 14, 2010 23:33
Manipulate cookies in JavaScript.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"></meta>
<script type="text/javascript" src="cookieUtil.js"></script>
<script>
cookieUtil.init();
$(function(){
$('form label').addClass('inline');
$('input:text, input:password').each(function(){
$(this).attr({'value':''})
});
$('input:text, input:password').focus(function(){
$(this).addClass('selected');
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<script class="jsbin" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Custom Accordion</title>
<style type="text/css">
html, body, div, h1, h3, h3, h4, h5, h6, ul, ol, dl, li, dt, dd, p, blockquote, pre, form, fieldset, label, table, th, td { margin: 0; padding: 0; }
<script type="text/javascript">
/* Function: Anonymous
* Schedule content to display between a start and end date.
*/
(function(){
var now = new Date();
var start = new Date("November 1, 2010 8:00:00");
var end = new Date("December, 17, 2010 11:59:00");
if(start < now && now < end){