From 8b38f0746c3f3e2267be8c67f2b282036f15ad51 Mon Sep 17 00:00:00 2001 From: Nikki Levy Date: Mon, 13 Jun 2016 09:49:05 +0200 Subject: [PATCH 1/2] Porfolio Project 2 V1 --- index.html | 10 ++++++++++ login.html | 5 ++++- script.js | 18 ++++++++++++++++-- 3 files changed, 30 insertions(+), 3 deletions(-) diff --git a/index.html b/index.html index eba471c..5e117d8 100644 --- a/index.html +++ b/index.html @@ -10,5 +10,15 @@ +
+
+
+
+

My Instagram

+
+
+
+
+
\ No newline at end of file diff --git a/login.html b/login.html index 6834241..eb5951a 100644 --- a/login.html +++ b/login.html @@ -4,13 +4,16 @@ Instamood | Login + + + - Log in with Instagram + Log in with Instagram \ No newline at end of file diff --git a/script.js b/script.js index 3d5e53b..785ac0a 100644 --- a/script.js +++ b/script.js @@ -22,6 +22,20 @@ $(document).ready(function() { }); function handleResponse(response) { - console.log(response); + for (var i=0; i"); + $("#list").append("
" + caption + "
"); + + } + // console.log(response); // add stuff here! -} \ No newline at end of file +} + + + // for (var i=0; i"+response.response.docs[i].headline.main+""); + // console.log(response.response.docs[i].headline.main) + // } \ No newline at end of file From bd528a215d8cf2d92cad26f5af9c98fb8aa9e52c Mon Sep 17 00:00:00 2001 From: Nikki Levy Date: Mon, 13 Jun 2016 15:58:08 +0200 Subject: [PATCH 2/2] Portfolio Project Updated Version --- index.html | 9 +++++++- script.js | 68 ++++++++++++++++++++++++++++++++++++++++++++++-------- style.css | 9 +++++++- 3 files changed, 74 insertions(+), 12 deletions(-) diff --git a/index.html b/index.html index 5e117d8..d074c52 100644 --- a/index.html +++ b/index.html @@ -7,6 +7,7 @@ + @@ -14,7 +15,13 @@
-

My Instagram

+

Instamood

+
+
Ego Score:
+ +
Active days:
+
Brevity:
+
Visibility Thirst:
diff --git a/script.js b/script.js index 785ac0a..f3c96c0 100644 --- a/script.js +++ b/script.js @@ -1,13 +1,13 @@ var API_DOMAIN = "https://api.instagram.com/v1"; var RECENT_MEDIA_PATH = "/users/self/media/recent"; -// what do you think a variable in all caps means? + $(document).ready(function() { var token = window.location.hash; if (!token) { window.location.replace("./login.html"); } - token = token.replace("#", "?"); // Prepare for query parameter + token = token.replace("#", "?"); var mediaUrl = API_DOMAIN + RECENT_MEDIA_PATH + token; $.ajax({ @@ -24,18 +24,66 @@ $(document).ready(function() { function handleResponse(response) { for (var i=0; i"); $("#list").append("
" + caption + "
"); + } + //console.log(response.data); + + +var selfLikes=0; + for (var i=0; i"+response.response.docs[i].headline.main+"
"); - // console.log(response.response.docs[i].headline.main) - // } \ No newline at end of file + + diff --git a/style.css b/style.css index 32d801f..865c2c0 100644 --- a/style.css +++ b/style.css @@ -1 +1,8 @@ -/*you fill this in*/ \ No newline at end of file +/*you fill this in*/ +body { + text-align: center; +} + +#list { + +} \ No newline at end of file