{"action":"created","comment":{"url":"https://api.github.com/repos/jonullberg/simple-site/pulls/comments/26459758","id":26459758,"diff_hunk":"@@ -0,0 +1,41 @@\n+$(document).ready(function() {\n+\t$(\"button\").on(\"click\", function() {\n+\t\tvar url = $(this).attr(\"id\");\n+\t\t$.get(url, function(response) {\n+\t\t\tvar resText;\n+\t\t\tif (typeof response === \"object\" && url == \"jokes\") {\n+\t\t\t\tresText = response.setup + \": \" + response.punchline;\n+\t\t\t} else if (typeof response === \"object\" && url == \"characters\") {\n+\t\t\t\tresText = response.character + \" is a character from \" + response.story;\n+\t\t\t} else {\n+\t\t\t\tresText = response;\n+\t\t\t}\n+\t\t\t$(\"#ajax-text\").text(resText);\n+\t\t});\n+\t});\n+\n+\t$.get(\"characters\", function(response) {\n+\t\tvar resText = response.character + \" from the book \" + response.story;\n+\t\t$(\"#daily-character\").text(resText);\n+\t});\n+\n+\t$(\"#piglatin\").on(\"submit\", function(e) {\n+\t\te.preventDefault();\n+\t\tvar firstname = $(\"input[name=firstname]\").val();\n+\t\tvar lastname = $(\"input[name=lastname]\").val();\n+\t\tvar name = { firstname: firstname, lastname: lastname };\n+\t\t$.post(\"piglatin\", name, function(response) {\n+\t\t\tvar piglatinified = response.firstname + \" \" + response.lastname;\n+\t\t\t$(\"#piglatinified\").text(piglatinified);\n+\t\t});\n+\t});\n+\t$(\"#spanglish\").on(\"submit\", function(e) {\n+\t\te.preventDefault();\n+\t\tvar sentenceInput = $(\"textarea[name=textInput]\").val();\n+\t\tvar sentenceSent = { sentenceInput: sentenceInput };\n+\t\t$.post(\"spanglish\", sentenceSent, function(response) {\n+\t\t\tvar spanglished = response.spanglishSentence;\n+\t\t\t$(\"#spanglished\").text(spanglished);\n+\t\t});","path":"app/script.js","position":39,"original_position":39,"commit_id":"c342082992705dbaaa4ceb41cb1608e5b7db6017","original_commit_id":"c342082992705dbaaa4ceb41cb1608e5b7db6017","user":{"login":"stephanielingwood","id":7757711,"avatar_url":"https://avatars.githubusercontent.com/u/7757711?v=3","gravatar_id":"","url":"https://api.github.com/users/stephanielingwood","html_url":"https://github.com/stephanielingwood","followers_url":"https://api.github.com/users/stephanielingwood/followers","following_url":"https://api.github.com/users/stephanielingwood/following{/other_user}","gists_url":"https://api.github.com/users/stephanielingwood/gists{/gist_id}","starred_url":"https://api.github.com/users/stephanielingwood/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephanielingwood/subscriptions","organizations_url":"https://api.github.com/users/stephanielingwood/orgs","repos_url":"https://api.github.com/users/stephanielingwood/repos","events_url":"https://api.github.com/users/stephanielingwood/events{/privacy}","received_events_url":"https://api.github.com/users/stephanielingwood/received_events","type":"User","site_admin":false},"body":"Good!","created_at":"2015-03-16T04:43:34Z","updated_at":"2015-03-16T04:43:34Z","html_url":"https://github.com/jonullberg/simple-site/pull/1#discussion_r26459758","pull_request_url":"https://api.github.com/repos/jonullberg/simple-site/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/jonullberg/simple-site/pulls/comments/26459758"},"html":{"href":"https://github.com/jonullberg/simple-site/pull/1#discussion_r26459758"},"pull_request":{"href":"https://api.github.com/repos/jonullberg/simple-site/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/jonullberg/simple-site/pulls/1","id":31067290,"html_url":"https://github.com/jonullberg/simple-site/pull/1","diff_url":"https://github.com/jonullberg/simple-site/pull/1.diff","patch_url":"https://github.com/jonullberg/simple-site/pull/1.patch","issue_url":"https://api.github.com/repos/jonullberg/simple-site/issues/1","number":1,"state":"open","locked":false,"title":"Added Spanglish and Piglatin functionality","user":{"login":"jonullberg","id":5409970,"avatar_url":"https://avatars.githubusercontent.com/u/5409970?v=3","gravatar_id":"","url":"https://api.github.com/users/jonullberg","html_url":"https://github.com/jonullberg","followers_url":"https://api.github.com/users/jonullberg/followers","following_url":"https://api.github.com/users/jonullberg/following{/other_user}","gists_url":"https://api.github.com/users/jonullberg/gists{/gist_id}","starred_url":"https://api.github.com/users/jonullberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonullberg/subscriptions","organizations_url":"https://api.github.com/users/jonullberg/orgs","repos_url":"https://api.github.com/users/jonullberg/repos","events_url":"https://api.github.com/users/jonullberg/events{/privacy}","received_events_url":"https://api.github.com/users/jonullberg/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-03-12T19:02:51Z","updated_at":"2015-03-16T04:43:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"104a52505a6696faaa48613ce9747da52df6b090","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/jonullberg/simple-site/pulls/1/commits","review_comments_url":"https://api.github.com/repos/jonullberg/simple-site/pulls/1/comments","review_comment_url":"https://api.github.com/repos/jonullberg/simple-site/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jonullberg/simple-site/issues/1/comments","statuses_url":"https://api.github.com/repos/jonullberg/simple-site/statuses/c342082992705dbaaa4ceb41cb1608e5b7db6017","head":{"label":"jonullberg:newPostText","ref":"newPostText","sha":"c342082992705dbaaa4ceb41cb1608e5b7db6017","user":{"login":"jonullberg","id":5409970,"avatar_url":"https://avatars.githubusercontent.com/u/5409970?v=3","gravatar_id":"","url":"https://api.github.com/users/jonullberg","html_url":"https://github.com/jonullberg","followers_url":"https://api.github.com/users/jonullberg/followers","following_url":"https://api.github.com/users/jonullberg/following{/other_user}","gists_url":"https://api.github.com/users/jonullberg/gists{/gist_id}","starred_url":"https://api.github.com/users/jonullberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonullberg/subscriptions","organizations_url":"https://api.github.com/users/jonullberg/orgs","repos_url":"https://api.github.com/users/jonullberg/repos","events_url":"https://api.github.com/users/jonullberg/events{/privacy}","received_events_url":"https://api.github.com/users/jonullberg/received_events","type":"User","site_admin":false},"repo":{"id":31693210,"name":"simple-site","full_name":"jonullberg/simple-site","owner":{"login":"jonullberg","id":5409970,"avatar_url":"https://avatars.githubusercontent.com/u/5409970?v=3","gravatar_id":"","url":"https://api.github.com/users/jonullberg","html_url":"https://github.com/jonullberg","followers_url":"https://api.github.com/users/jonullberg/followers","following_url":"https://api.github.com/users/jonullberg/following{/other_user}","gists_url":"https://api.github.com/users/jonullberg/gists{/gist_id}","starred_url":"https://api.github.com/users/jonullberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonullberg/subscriptions","organizations_url":"https://api.github.com/users/jonullberg/orgs","repos_url":"https://api.github.com/users/jonullberg/repos","events_url":"https://api.github.com/users/jonullberg/events{/privacy}","received_events_url":"https://api.github.com/users/jonullberg/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jonullberg/simple-site","description":"skeleton repository for server workshop -- Foundations II JavaScript, Code Fellows.","fork":true,"url":"https://api.github.com/repos/jonullberg/simple-site","forks_url":"https://api.github.com/repos/jonullberg/simple-site/forks","keys_url":"https://api.github.com/repos/jonullberg/simple-site/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jonullberg/simple-site/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jonullberg/simple-site/teams","hooks_url":"https://api.github.com/repos/jonullberg/simple-site/hooks","issue_events_url":"https://api.github.com/repos/jonullberg/simple-site/issues/events{/number}","events_url":"https://api.github.com/repos/jonullberg/simple-site/events","assignees_url":"https://api.github.com/repos/jonullberg/simple-site/assignees{/user}","branches_url":"https://api.github.com/repos/jonullberg/simple-site/branches{/branch}","tags_url":"https://api.github.com/repos/jonullberg/simple-site/tags","blobs_url":"https://api.github.com/repos/jonullberg/simple-site/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jonullberg/simple-site/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jonullberg/simple-site/git/refs{/sha}","trees_url":"https://api.github.com/repos/jonullberg/simple-site/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jonullberg/simple-site/statuses/{sha}","languages_url":"https://api.github.com/repos/jonullberg/simple-site/languages","stargazers_url":"https://api.github.com/repos/jonullberg/simple-site/stargazers","contributors_url":"https://api.github.com/repos/jonullberg/simple-site/contributors","subscribers_url":"https://api.github.com/repos/jonullberg/simple-site/subscribers","subscription_url":"https://api.github.com/repos/jonullberg/simple-site/subscription","commits_url":"https://api.github.com/repos/jonullberg/simple-site/commits{/sha}","git_commits_url":"https://api.github.com/repos/jonullberg/simple-site/git/commits{/sha}","comments_url":"https://api.github.com/repos/jonullberg/simple-site/comments{/number}","issue_comment_url":"https://api.github.com/repos/jonullberg/simple-site/issues/comments{/number}","contents_url":"https://api.github.com/repos/jonullberg/simple-site/contents/{+path}","compare_url":"https://api.github.com/repos/jonullberg/simple-site/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jonullberg/simple-site/merges","archive_url":"https://api.github.com/repos/jonullberg/simple-site/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jonullberg/simple-site/downloads","issues_url":"https://api.github.com/repos/jonullberg/simple-site/issues{/number}","pulls_url":"https://api.github.com/repos/jonullberg/simple-site/pulls{/number}","milestones_url":"https://api.github.com/repos/jonullberg/simple-site/milestones{/number}","notifications_url":"https://api.github.com/repos/jonullberg/simple-site/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jonullberg/simple-site/labels{/name}","releases_url":"https://api.github.com/repos/jonullberg/simple-site/releases{/id}","created_at":"2015-03-05T03:15:32Z","updated_at":"2015-03-05T03:15:33Z","pushed_at":"2015-03-12T18:47:20Z","git_url":"git://github.com/jonullberg/simple-site.git","ssh_url":"git@github.com:jonullberg/simple-site.git","clone_url":"https://github.com/jonullberg/simple-site.git","svn_url":"https://github.com/jonullberg/simple-site","homepage":"","size":158,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"jonullberg:master","ref":"master","sha":"941cf4152660cc72ec072eae96a45368dc1ffa10","user":{"login":"jonullberg","id":5409970,"avatar_url":"https://avatars.githubusercontent.com/u/5409970?v=3","gravatar_id":"","url":"https://api.github.com/users/jonullberg","html_url":"https://github.com/jonullberg","followers_url":"https://api.github.com/users/jonullberg/followers","following_url":"https://api.github.com/users/jonullberg/following{/other_user}","gists_url":"https://api.github.com/users/jonullberg/gists{/gist_id}","starred_url":"https://api.github.com/users/jonullberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonullberg/subscriptions","organizations_url":"https://api.github.com/users/jonullberg/orgs","repos_url":"https://api.github.com/users/jonullberg/repos","events_url":"https://api.github.com/users/jonullberg/events{/privacy}","received_events_url":"https://api.github.com/users/jonullberg/received_events","type":"User","site_admin":false},"repo":{"id":31693210,"name":"simple-site","full_name":"jonullberg/simple-site","owner":{"login":"jonullberg","id":5409970,"avatar_url":"https://avatars.githubusercontent.com/u/5409970?v=3","gravatar_id":"","url":"https://api.github.com/users/jonullberg","html_url":"https://github.com/jonullberg","followers_url":"https://api.github.com/users/jonullberg/followers","following_url":"https://api.github.com/users/jonullberg/following{/other_user}","gists_url":"https://api.github.com/users/jonullberg/gists{/gist_id}","starred_url":"https://api.github.com/users/jonullberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonullberg/subscriptions","organizations_url":"https://api.github.com/users/jonullberg/orgs","repos_url":"https://api.github.com/users/jonullberg/repos","events_url":"https://api.github.com/users/jonullberg/events{/privacy}","received_events_url":"https://api.github.com/users/jonullberg/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jonullberg/simple-site","description":"skeleton repository for server workshop -- Foundations II JavaScript, Code Fellows.","fork":true,"url":"https://api.github.com/repos/jonullberg/simple-site","forks_url":"https://api.github.com/repos/jonullberg/simple-site/forks","keys_url":"https://api.github.com/repos/jonullberg/simple-site/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jonullberg/simple-site/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jonullberg/simple-site/teams","hooks_url":"https://api.github.com/repos/jonullberg/simple-site/hooks","issue_events_url":"https://api.github.com/repos/jonullberg/simple-site/issues/events{/number}","events_url":"https://api.github.com/repos/jonullberg/simple-site/events","assignees_url":"https://api.github.com/repos/jonullberg/simple-site/assignees{/user}","branches_url":"https://api.github.com/repos/jonullberg/simple-site/branches{/branch}","tags_url":"https://api.github.com/repos/jonullberg/simple-site/tags","blobs_url":"https://api.github.com/repos/jonullberg/simple-site/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jonullberg/simple-site/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jonullberg/simple-site/git/refs{/sha}","trees_url":"https://api.github.com/repos/jonullberg/simple-site/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jonullberg/simple-site/statuses/{sha}","languages_url":"https://api.github.com/repos/jonullberg/simple-site/languages","stargazers_url":"https://api.github.com/repos/jonullberg/simple-site/stargazers","contributors_url":"https://api.github.com/repos/jonullberg/simple-site/contributors","subscribers_url":"https://api.github.com/repos/jonullberg/simple-site/subscribers","subscription_url":"https://api.github.com/repos/jonullberg/simple-site/subscription","commits_url":"https://api.github.com/repos/jonullberg/simple-site/commits{/sha}","git_commits_url":"https://api.github.com/repos/jonullberg/simple-site/git/commits{/sha}","comments_url":"https://api.github.com/repos/jonullberg/simple-site/comments{/number}","issue_comment_url":"https://api.github.com/repos/jonullberg/simple-site/issues/comments{/number}","contents_url":"https://api.github.com/repos/jonullberg/simple-site/contents/{+path}","compare_url":"https://api.github.com/repos/jonullberg/simple-site/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jonullberg/simple-site/merges","archive_url":"https://api.github.com/repos/jonullberg/simple-site/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jonullberg/simple-site/downloads","issues_url":"https://api.github.com/repos/jonullberg/simple-site/issues{/number}","pulls_url":"https://api.github.com/repos/jonullberg/simple-site/pulls{/number}","milestones_url":"https://api.github.com/repos/jonullberg/simple-site/milestones{/number}","notifications_url":"https://api.github.com/repos/jonullberg/simple-site/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jonullberg/simple-site/labels{/name}","releases_url":"https://api.github.com/repos/jonullberg/simple-site/releases{/id}","created_at":"2015-03-05T03:15:32Z","updated_at":"2015-03-05T03:15:33Z","pushed_at":"2015-03-12T18:47:20Z","git_url":"git://github.com/jonullberg/simple-site.git","ssh_url":"git@github.com:jonullberg/simple-site.git","clone_url":"https://github.com/jonullberg/simple-site.git","svn_url":"https://github.com/jonullberg/simple-site","homepage":"","size":158,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jonullberg/simple-site/pulls/1"},"html":{"href":"https://github.com/jonullberg/simple-site/pull/1"},"issue":{"href":"https://api.github.com/repos/jonullberg/simple-site/issues/1"},"comments":{"href":"https://api.github.com/repos/jonullberg/simple-site/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/jonullberg/simple-site/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/jonullberg/simple-site/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jonullberg/simple-site/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/jonullberg/simple-site/statuses/c342082992705dbaaa4ceb41cb1608e5b7db6017"}}}}