Skip to content

Instantly share code, notes, and snippets.

View susanBuck's full-sized avatar

Susan Buck susanBuck

View GitHub Profile
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Ohanarama: Fun family games, family memories, and kids activities - for FREE!</title>
<link rel="shortcut icon" href="favicon.ico">
<meta name="copyright" content="Copyright 2011 Ohanarama. All rights reserved.">
<meta name="author" content="Ohanarama"><meta name="robots" content="index, follow">
@charset "UTF-8";
/* CSS Document */
.centered {
text-align: center;
}
html {
height: 100%;
@susanBuck
susanBuck / day-or-night.php
Created February 16, 2012 03:52
day-or-night
<!doctype html>
<head>
<?
$time = date("G");
if($time < 20) {
$background_color = "#37BDBD";
}
else {
<!DOCTYPE html>
<html>
<head>
<title>Random Drawing</title>
<?php
# Who are our contestants?
$contestants["Bob"] = "";
$contestants["Frank"] = "";
@susanBuck
susanBuck / less-color-palette
Created March 14, 2012 22:41
less-color-palette
function print_colors($filename) {
$handle = fopen($filename, "rb");
$colors = fread($handle, filesize($filename));
$colors = explode(";", $colors);
foreach($colors as $color_info) {
$color = explode("#", $color_info);
$color = $color[1];
<!DOCTYPE html>
<head>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.0/jquery.min.js"></script>
<script type='text/javascript'>
$(document).ready(function() {
ALTER TABLE `orders_activity` CHANGE `totalAdjustments` `pc_total` FLOAT;
ALTER TABLE `orders_activity` CHANGE `totalAdjustments_transactionFee` `pc_total_transaction_fee` FLOAT NULL;
ALTER TABLE `orders_activity` CHANGE `totalAdjustments_costOfItems` `pc_total_items` FLOAT NOT NULL;
ALTER TABLE `orders_activity` CHANGE `totalAdjustments_fulfillmentFee` `pc_total_fulfillment` FLOAT NULL;
ALTER TABLE `orders_activity` CHANGE `totalAdjustments_miscTotal` `pc_total_misc` FLOAT NULL;
ALTER TABLE `orders_activity` CHANGE `totalAdjustments_miscDetails` `pc_misc_with_description` TEXT NULL;
ALTER TABLE `orders_activity` MODIFY COLUMN `pc_total` FLOAT DEFAULT NULL AFTER `transactionId`;
ALTER TABLE `orders_activity` MODIFY COLUMN `pc_total_transaction_fee` FLOAT DEFAULT NULL AFTER `pc_total`;
ALTER TABLE `orders_activity` MODIFY COLUMN `pc_total_items` FLOAT DEFAULT NULL AFTER `pc_total_transaction_fee`;
@susanBuck
susanBuck / geolocation
Created June 1, 2012 08:08
geolocation
function locate() {
// first try to use geoIP library for IP address, since it uses it's own IP detection
$ip = $_SERVER['GEOIP_ADDR'];
if (empty($ip))
$ip = self::ip_address();
// if we're on the localhost inject an IP address
if ($_SERVER["SERVER_NAME"] == "localhost")
@susanBuck
susanBuck / basic-html-template
Last active October 9, 2015 14:38
Basic HTML template
<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body>
@susanBuck
susanBuck / gist:3592765
Created September 2, 2012 00:52
Nicole's HTML Poem
<!DOCTYPE html>
<head>
<title>Planetarium by Adrienne Rich</title>
</head>
<body>