added availability and image per isbn
This commit is contained in:
parent
15bd367762
commit
d6d8c778eb
|
@ -1,5 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
require("common.php");
|
require("common.php");
|
||||||
|
require("isbnImage.php");
|
||||||
function bookDisplay($pdo, $id)
|
function bookDisplay($pdo, $id)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -61,7 +62,17 @@ function bookDisplay($pdo, $id)
|
||||||
<div class="w3-card w3-round w3-white">
|
<div class="w3-card w3-round w3-white">
|
||||||
<div class="w3-container">
|
<div class="w3-container">
|
||||||
<h4 class="w3-center"><?php echo htmlentities($data["Titolo"]); ?></h4>
|
<h4 class="w3-center"><?php echo htmlentities($data["Titolo"]); ?></h4>
|
||||||
<center><img style="width:10vw" src="books.png" /></center>
|
<?php
|
||||||
|
$image = isbnImage($data["ISBN"]);
|
||||||
|
?>
|
||||||
|
<center><a href="<?php
|
||||||
|
if($image=="books.png"){
|
||||||
|
echo "#";
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
echo $image;
|
||||||
|
}
|
||||||
|
?>"><img style="width:10vw" src="<?php echo $image; ?>" /></a></center>
|
||||||
<hr>
|
<hr>
|
||||||
<?php
|
<?php
|
||||||
if ($data["Autore"]) {
|
if ($data["Autore"]) {
|
||||||
|
@ -99,6 +110,7 @@ function bookDisplay($pdo, $id)
|
||||||
<div class="w3-card w3-round">
|
<div class="w3-card w3-round">
|
||||||
<div class="w3-white">
|
<div class="w3-white">
|
||||||
<?php
|
<?php
|
||||||
|
if($GLOBALS["availability"]){
|
||||||
if ($data["Prestito"] == "P") {
|
if ($data["Prestito"] == "P") {
|
||||||
?>
|
?>
|
||||||
<button onclick="myFunction('Demo1')" class="w3-button w3-block w3-theme-l1 w3-left-align" style="background-color:red!important"><i class="fa fa-circle-o-notch fa-fw w3-margin-right"></i> In prestito</button>
|
<button onclick="myFunction('Demo1')" class="w3-button w3-block w3-theme-l1 w3-left-align" style="background-color:red!important"><i class="fa fa-circle-o-notch fa-fw w3-margin-right"></i> In prestito</button>
|
||||||
|
@ -114,6 +126,7 @@ function bookDisplay($pdo, $id)
|
||||||
</div>
|
</div>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
}
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
|
Reference in New Issue
Block a user