From 5c0698e277b239991d02902fdb2b52c4b52c8a58 Mon Sep 17 00:00:00 2001 From: AvarageCodeEnjoyer <111468739+AvarageCodeEnjoyer@users.noreply.github.com> Date: Mon, 8 Jan 2024 14:52:59 -0700 Subject: [PATCH] Fixed Access token being loaded into github --- index.html | 10 ++++++++-- index.js | 3 ++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/index.html b/index.html index c1886a1..7ac445d 100644 --- a/index.html +++ b/index.html @@ -8,8 +8,14 @@
- - +
+ + +
+
+ + +
Caption:
diff --git a/index.js b/index.js index d21cd75..e39222b 100644 --- a/index.js +++ b/index.js @@ -1,6 +1,7 @@ async function getData() { const postNumber = document.getElementById('postNumber').value; - const results = await fetch("https://graph.instagram.com/me/media?fields=media_url,caption,timestamp,media_type&access_token=IGQWRQYm5yUDhNOEQwRERqSi1FNVNpTVYwVURxRjZAGTFpOVXBhTTJ1SkVId2pDMjV0WG83Q1Frd0dLcmpRd3RqMk5nUDluWTl1MlprNWR4MmpnU0ZAnaVJfQl9kTjJ0Y2NfZA0U3VmxMcEstaXdid3NLZAEpqcUZAzTG50NW9PQUxuRVlqZAwZDZD") + const accessToken = document.getElementById('accessToken').value + const results = await fetch(`https://graph.instagram.com/me/media?fields=media_url,caption,timestamp,media_type&access_token=${accessToken}`) const result = await results.json() document.getElementById("id").innerHTML += result.data[postNumber].id