I'm trying to get the Google Books API to return the Book Edition number. IE: 3rd Edition, 7th, Illustrated, ect.
Using the following code, I can basically get everything I could ever want to find out about the book by changing or adding a few objectType changes. EXCEPT the edition type.
<html>
<head>
<title>Books API Example</title>
</head>
<body>
<div id="content"></div>
<script>
function handleResponse(response) {
for (var i = 0; i < response.items.length; i++) {
var item = response.items[i];
// in production code, item.text should have the HTML entities escaped.
document.getElementById("content").innerHTML += "<br>" + item.volumeInfo.title + " : " + item.volumeInfo.subtitle
+ "<br>" + item.volumeInfo.authors + " "
+ "<br>" + "<img src='" + item.volumeInfo.imageLinks.thumbnail + "'> <br>";
}
}
</script>
<script src="https://www.googleapis.com/books/v1/volumes?q=isbn:1435497783&callback=handleResponse"></script>
</body>
Here are the parameters https://developers.google.com/books/docs/v1/reference/volumes
Anyone know anything about the edition for the volume? EDIT: Also, would anyone be willing to show me how I can do basically an 'if' statement for a subtitle. If the book has one, I want to display it. But if it doesn't, I dont want undefined sitting next to the title.