Skip to content

Instantly share code, notes, and snippets.

View mrandyclark's full-sized avatar

Andrew Clark mrandyclark

View GitHub Profile
#model for drinks
belongs_to :person
var map = ["string", "string2"]
$.each(map, function(key, value) {
alert(key + ': ' + value);
});
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<META name="y_key" content="cad3f627043ad8fe">
<meta name="msvalidate.01" content="03698D8D9E3442108B1FE6E16A8E19EF" />
<meta name="google-site-verification" content="qFvIH3xt2gnvFYHZr2ZaSLSAL2TbRmPKpnmJAHMT-_I" />
<meta name="keywords" content="<%= @meta_keywords || "web, design, development, applications, apps, deployment, hosting, marketing, Warsaw, Indiana, South Bend, Fort Wayne, Winona Lake" %>" />
<meta name="description" content="<%= @meta_description || "Disruptive Ventures builds disruptive businesses." %>" />
<title><%= @page_title || "Disruptive Ventures, Inc." %></title>
<!-- this is the "layout" for the whole site -->
<!-- the container. should have a width and margin: 0px auto; -->
<div id="container">
<div id="header"> header </div>
<!-- this has the faux columns. bg:url(bg-image.png), overflow: hidden, etc -->
<!-- has a width ( col1 width + col1 padding + col2 width + col2 padding -->
<div id="main">
var pirates = ["pirate1", "pirate2", "pirate3", "pirate4", "pirate5"];
var distanceToGo = 20;
var newPirates = true;
var getMorePirates = function(pirates) {
pirates.push(
"pirate" +
(pirates.length+1)
);
console.log("we've ordered some new pirates!");
puts 'Hello. What year would you like to begin with?'
@alpha_year = gets.chomp
puts 'What year would you like to end with?'
@omega_year = gets.chomp
while(@alpha_year <= @omega_year)
puts @alpha_year
puts @alpha_year%4
var startYear = 2000;
var endYear = 2020;
while(startYear <= endYear)
{
if(startYear%4 == 0 && (startYear%100 != 0 && startYear%400 != 0))
{
console.log(startYear);
}
startYear++
# If you put in a beginning year and an end year, it should spit out a list of
# all of the leap years in between.
puts 'Hello. What year would you like to begin with?'
@start_year=gets.chomp
puts 'What year would you like to end with?'
@end_year=gets.chomp
input=''
while @start_year < @end_year
NameVirtualHost *:80
NameVirtualHost *:443
<VirtualHost *:80>
ServerName domain.com
ServerAlias www.domain.com
DocumentRoot path/to/app/current/public
DirectoryIndex index.html
@mrandyclark
mrandyclark / index.html
Created June 8, 2010 12:39
Easy jQuery Tabs
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>Simple Tabs</title>