Skip to content

Instantly share code, notes, and snippets.

View robynitp's full-sized avatar

Robyn Overstreet robynitp

  • NYU ITP
  • New York, NY
View GitHub Profile
@robynitp
robynitp / object_literal.js
Last active August 29, 2015 13:57
A basic Javascript object literal
var employee = {
name: 'Jane',
dob: '04-09-80',
position: 'Art Director',
start_date: '10-14-2011',
subordinates: ['Jack','Jill','Edward'],
work: function(){
console.log('I make stuff');
},
employee_id: 23452
@robynitp
robynitp / weather_example.json
Last active August 29, 2015 13:58
Example JSON text
{
"coord": {
"lon": -76.61,
"lat": 39.29
},
"sys": {
"message": 0.0441,
"country": "United States of America",
"sunrise": 1396953525,
"sunset": 1397000248
[
{
"name": "Robyn",
"number": "3543"
},
{
"name": "Opal",
"number": "1123"
},
{
[
{
"Name": "Brett Stiller",
"URL": "http://brettstiller.xyz/?cat=6"
},
{
"Name": "Catherine Rehwinkel",
"URL": "http://www.catherinerehwinkel.com/itp-nyu/"
},
{
{
"last_names":[
"Smith",
"Johnson",
"Williams",
"Jones",
"Brown",
"Davis",
"Miller",
"Wilson",
[
{
"id": "1",
"start_time": "2013-12-30 7:45",
"end_time": "2013-12-30 8:21",
"activity": "Initial search with radio for sakis"
},
{
"id": "2",
"start_time": "2013-12-30 8:21",
{
"coord": {
"lon": -74.01,
"lat": 40.71
},
"sys": {
"type": 1,
"id": 1980,
"message": 0.115,
"country": "US",
@robynitp
robynitp / README.md
Last active August 29, 2015 14:10
Servi Step By Step

Networked Media Week 5 Assignment

Create a server in Servi to manage a simple web site. The site will have, at minimum, the following pages:

  • Home page
  • A static page, for example, "About" or "FAQ"
  • A set of dynamically generated pages that all have the same structure but contain different data. For example, in an online store, each product has its own page and all of the product pages use the same template.

The focus of this assignment is process over product. You will build out the site using an iterative process, starting small and adding new features to your project as you go. Instead of turning in a URL to a live server, as we've done in previous assignments, you'll turn in a link to a gist project containing 3 files.

@robynitp
robynitp / index.html
Last active August 29, 2015 14:10
Show and hide divs based on click
<!DOCTYPE HTML>
<html>
<head>
<title>Hello World</title>
<!-- the jquery script from the internet -->
<script src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
<!-- your custom javascript -->
<script src="onescript.js"></script>
<!-- CSS : look at this file to see how things are styled-->
<link rel="stylesheet" type="text/css" href="mystyle.css">
@robynitp
robynitp / servi-load-stuff.js
Last active August 29, 2015 14:10
load URL and load JSON file in servi.js
var servi = require('servi');
var app = new servi(true);
var http = require('http');
start();
route('/', showHome);
function showHome(request){
// load a local JSON file
loadJSON('weather.json',function(data){