Play with Instagram API
How do I make an play with instagram api?
Play using Instagram's API and some straight-forward but fun CSS/Bootstrap framework customization.. What is a play with instagram api? How do you make a play with instagram api? This script and codes were developed by Tess DiNapoli on 14 January 2023, Saturday.
Play with Instagram API - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Play with Instagram API</title> <link rel='stylesheet prefetch' href='https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css'> <link rel="stylesheet" href="css/style.css">
</head>
<body> <!--FONT AWESOME FOR ICONS--> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css"> <!--GOOGLEFONT--> <link href='https://fonts.googleapis.com/css?family=Fredoka+One' rel='stylesheet' type='text/css'>
</head>
<body> <div class="container"> <div class="row"> <div class="col-md-6 col-md-offset-3"> <div class="panel panel-primary"> <div class="panel-heading"> <i class="fa fa-camera-retro fa-4x"></i> <h1>Play with Instagram's API</h1> <div class="panel-body"> <div class="form-group"> <input id="search" placeholder="search hashtags" type="text" class="form-control"> <br> <button class="btn btn-info" id="searchBtn">Explore!</button> </div> </div> </div> </div> </div> </div> <!--IG DATA TO POPULATE HERE--> <div class="row"> <div id="results"></div> </div> </div> </div> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.2.2/jquery.min.js'></script>
<script src='http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js'></script> <script src="js/index.js"></script>
</body>
</html>
Play with Instagram API - Script Codes CSS Codes
html, body { background-image: url("http://www.publicdomainpictures.net/pictures/20000/velka/fresh-spring-background.jpg"); background-repeat: no-repeat; background-size: cover;
}
.panel-primary { text-align: center; margin-top: 30px;
}
h1 { font-family: "Fredoka One", sans-serif;
}
img { border-radius: 50%; height: 180px;
}
#results { margin: 0 auto; padding-left: 40px;
}
Play with Instagram API - Script Codes JS Codes
function searchHashtags(searchInput) { var searchInput = document.getElementById("search").value document.getElementById("results").textContent = "" console.log(searchInput) $.ajax({ type: "GET", dataType: "jsonp", url: "https://api.instagram.com/v1/tags/" + searchInput + "/media/recent?access_token=183464849.1677ed0.a44700126e6f4b5cb8140fab000bcfe6", jsonp: "callback", success: function(data) { console.log(data) for(var i = 0; i < data.data.length; i++) { var newATag = document.createElement("a") newATag.setAttribute("href", data.data[i].link + " 'target='_blank'") var newDiv = document.createElement("div") newDiv.className = "col-xs-6 col-sm-3" var igImgThumb = document.createElement("img") igImgThumb.setAttribute("src", data.data[i].images.thumbnail.url) newDiv.appendChild(igImgThumb) var igLike = document.createElement("h4") var currLikes = document.createTextNode("Love: " + data.data[i].likes.count) var igUserH = document.createElement("h5") var igUser = document.createTextNode("captured by: " + data.data[i].caption.from.username) igUserH.appendChild(igUser) newDiv.appendChild(igUserH) newATag.appendChild(newDiv) document.getElementById("results").appendChild(newATag) } }, type: "GET" })
}
document.getElementById("searchBtn").addEventListener("click", searchHashtags, false)
Developer | Tess DiNapoli |
Username | TessDiNapoli |
Uploaded | January 14, 2023 |
Rating | 3 |
Size | 2,903 Kb |
Views | 4,048 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
JQuery ui experiments | 1,957 Kb |
Daily Task List | 2,254 Kb |
Feedback Page | 2,836 Kb |
Play with Instagram API | 2,903 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
A bit of elegance | Hackthevoid | 9,095 Kb |
Material design buttons | Fischaela | 4,381 Kb |
Slide out Menu | Rbiggs | 4,936 Kb |
Flexbox playground | Enxaneta | 5,418 Kb |
Wikipedia Viewer | Odylic | 2,333 Kb |
Sticky footer testing | 75th | 1,649 Kb |
CSS Social Media Icon | TychoBlender | 3,871 Kb |
Jochaho Skeleton | Dhanushbadge | 1,689 Kb |
Simple jQuery Slider | Jurbank | 2,874 Kb |
Haml Calendar | Katydecorah | 5,643 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!