Advertisement
Guest User

Untitled

a guest
Jan 27th, 2016
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 4.33 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html lang="it">
  3. <head>
  4.   <title> Bicicletteria </title>
  5.   <link rel="stylesheet" href="style/theme.css"/>
  6.   <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
  7.   <script src="scripts/popup.js" type="text/javascript"></script>
  8.   <script src="scripts/change_quantity.js" type="text/javascript"></script>
  9.   <script src="scripts/change_image.js" type="text/javascript"></script>
  10. </head>
  11. <body>
  12. <?php
  13.     $servername = "http:\\www.bicicletteria.altervista.org";
  14.     $username = "bicicletteria";
  15.     $password = "rikwedinti32";
  16.     $dbname = "my_bicicletteria";
  17.  
  18.     // Create connection
  19.     $conn = new mysqli($servername, $username, $password, $dbname);
  20.     // Check connection
  21.     if ($conn->connect_error) {
  22.         die("Connection failed: " . $conn->connect_error);
  23.     }
  24.   ?>
  25.  
  26.   <div id = "pop_background"></div>
  27.  
  28.   <div id ="pop_box">
  29.     <span id="close_button">&times;</span>
  30.     <h1>Hai qualche domanda?</h1>
  31.     <p>Vuoi avere maggiori informazioni sui nostri prodotti?<br> Ti bastera' compilare questo form e ti risponderemo il prima possibile </p>
  32.     <form action="action_page.php">
  33.       <label for="name">Nome*: <input type="text" name="name"></label>
  34.       <label for="email">Email*: <input type="text" name="email"></label>
  35.       <label for="text" id ="mex">Messaggio: <textarea  rows="10" cols="21" name="message"></textarea></label> <!--  -->
  36.     <label for="send" > <button id="send">Invia messaggio</button></label>
  37.     </form>
  38.   </div>
  39.  
  40.  
  41.   <header id="top">
  42.     <img id="logo" src="http://bicicletteria.altervista.org/image/logo.png" alt="Bicicletteria">
  43.     <nav id="topmenu">
  44.       <ul>
  45.         <li class=home><a href="/index.html">HOME</a></li>
  46.         <li class=catalogo><a href="....">CATALOGO</a></li>
  47.         <li class=chi_siamo><a href="/chi_siamo.html">CHI SIAMO</a></li>
  48.         <li><a href="#" id ="open">CONTATTACI</a></li>
  49.         <li><a href="....">CARRELLO</a></li>
  50.       </ul>
  51.     </nav>
  52.     <section id="ricerca">
  53.       <form name="ricerca" method="post" action="/search">
  54.         <input type="search" class="srcbar" id="s" name="search" placeholder="Cerca sul sito">
  55.         <input type="submit" class="srcbar" id= "buttonsearch" value="Cerca">
  56.       </form>
  57.     </section>
  58.     <section id="login">
  59.       <img src="https://en.opensuse.org/images/0/0b/Icon-user.png" alt="login" width="15px" height="15px">
  60.       <a href="/login.html">LOGIN</a>
  61.     </section>
  62.  
  63.   </header>
  64.  
  65.   <div id="container">
  66.     <span id="up">
  67.       <span id="sinistra">
  68.       <?php
  69.         $sql = "SELECT * FROM Bici where ID_bici =" . $_GET['ID_bici'];
  70.  
  71.         $result = $conn->query($sql);
  72.  
  73.         if ($result->num_rows > 0) {
  74.          $row = $result->fetch_array();
  75.        
  76.         echo "<img src='".$row[8]."'>";
  77.         echo "<img src='".$row[9]."'>";
  78.         echo "<img src='".$row[10]."'>";
  79.         echo "<img src='".$row[11]."'>";
  80.         echo "<img src='".$row[12]."'>";
  81.         echo "<img src='".$row[13]."'>";
  82.         }
  83.       ?>
  84.       </span>
  85.       <span id="centro">
  86.       <?php
  87.         echo "<img id='main' src='".$row[8]."'>";
  88.        
  89.         echo"<p id='desc'>$row[2]</p>";
  90.       ?>
  91.    
  92.       </span>
  93.       <span id="destra">
  94.       <?php
  95.         echo"<p id='nome_prodotto'>$row[1]</p>";
  96.         echo"<p id='marca'>$row[4]</p>";
  97.         echo"<p id='prezzo'>$row[3]</p>";
  98.       ?>
  99.        
  100.         <form>
  101.           <select name="dimensione" id="dimensione">
  102.             <option value="24" selected ="selected" title="24''">24''</option>
  103.             <option value="26" title="26''">26''</option>
  104.             <option value="28" title="28''">28''</option>
  105.           </select>
  106.           <div class="choose_quantity">
  107.               <span class="label">Quantita:</span>
  108.                   <button class="less">-</button>
  109.                   <input id="qnt" type="text" value="1">
  110.                   <button class="more">+</button>
  111.           </div>
  112.           <button id="add">Aggiungi al carrello</button>
  113.         </form>
  114.       </span>
  115.     </span>
  116.   </div>
  117.  
  118.   <footer>
  119.     <dl>
  120.       <dt>Autori:</dt>
  121.       <dd>Simone Letizi</dd>
  122.       <dd>Davide Borficchia</dd>
  123.       <br>
  124.       <dt> Sito web progettato a fini scolastici - Progetto di Tecnologie Web 2015/2016, Università di Bologna sede di Cesena</dt>
  125.     </dl>
  126.   </footer>
  127.  
  128.   </body>
  129. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement