Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Ino4 authored Jun 30, 2017
1 parent 2aa2f5c commit 1d9484a
Show file tree
Hide file tree
Showing 30 changed files with 12,330 additions and 0 deletions.
Binary file added Ello Globe.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added address.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added background.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added bg.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added company.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
75 changes: 75 additions & 0 deletions db.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
<html>
<head>
<link rel="stylesheet" href="style.css">
<!-- IMPORT JQUERY HERE -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js" type="text/javascript"></script>
<!-- END -->

<!-- WRITE YOUR OWN SCRIPT HERE FOR THE AJAX REQUEST -->
<script>
$(document).ready(function() {
$("#loadButton").click(function() {
var root = 'https://jsonplaceholder.typicode.com';
var inputid = $("#idField").val();
$.ajax({
// url: root + '/photos?id=' + inputid,
url: root + '/photos/',
data: {
albumId: inputid
},
type: "GET",
dataType: "json",
success: function(data) {
if (data.Response == "False") {
$("#title").html("<p>NOT A VALID PHOTO.</p>");
$("#poster").attr("src", "");
}
else {
$("#title").html("<p>" + data[1].title + "</p>");
$("#poster").attr("src", data[1].thumbnailUrl);
console.log(data);
}
}
});
// .done(function (data) {
// $("#plot").html("<p>" + data[0].title + "</p>");
// $("#poster").attr("src", data[0].thumbnailUrl);
// console.log(data);
// $("#plot").empty();
// $.each(data, function (i) {
// $("#plot").append("<p>" + this.title + "</p>");
// })
// })
// .fail(function( xhr, status, errorThrown ) {
// alert( "Sorry, there was a problem!" );
// console.log( "Error: " + errorThrown );
// console.log( "Status: " + status );
// console.dir( xhr );
// });
});
});
</script>

</head>
<body>
<div id="content">
<h1>Sample AJAX App</h1>
<label>Enter user ID:</label>
<input id="idField" type="text">
<button id="loadButton">LOAD</button>
<div id="wrapper">
<div id="mainDiv">
<h4>Title</h4>
<div id="title">
No title to show.
</div>
</div>
<div id="secondDiv">
<h4>Photo</h4>
<img id="poster" alt="No photo loaded yet">
</div>
</div>
</div>
<!-- END -->
</body>
</html>
Binary file added email.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 1d9484a

Please sign in to comment.