142 lines
3.0 KiB
PHP
142 lines
3.0 KiB
PHP
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<link rel="stylesheet" type="text/css" href="css/style.css" />
|
|
|
|
</head>
|
|
<body>
|
|
<div id="wrapper">
|
|
<div id="logo">
|
|
<img src="images/logo.png" />
|
|
</div>
|
|
<div id="menu">
|
|
<ul>
|
|
<li><a href="#" class="active">Strona główna</a></li>
|
|
<li><a href="#">O mnie</a></li>
|
|
<li><a href="#">Oferta</a></li>
|
|
<li><a href="#">Kontakt</a></li>
|
|
</ul>
|
|
</div>
|
|
<div id="header">
|
|
<img src="images/bg_head.jpg" style="float: right" />
|
|
<div id="title_head">
|
|
<h2>Skaner kodów QR</h2>
|
|
<span><?php
|
|
|
|
$conn = new mysqli("localhost", "root", "", "komputery") or die("Błąd");
|
|
|
|
$wynik = $conn->query("SELECT * FROM parametry WHERE Id = 3 ");
|
|
|
|
echo "<h1>Dane twojego komputera: </h1>";
|
|
echo "<br>";
|
|
|
|
if($wynik->num_rows > 0){
|
|
|
|
echo "<table style='border-spacing: 10px; border-collapse: collapse;' border='3'>";
|
|
echo "<tr>";
|
|
|
|
echo "<th>Procesor</th>";
|
|
echo "<th>Plyta_Glowna</th>";
|
|
echo "<th>Pamiec_Ram</th>";
|
|
echo "<th>Dysk</th>";
|
|
echo "<th>Karta_Graficzna</th>";
|
|
echo "</tr>";
|
|
|
|
|
|
|
|
while( $wiersz = $wynik->fetch_assoc() ){
|
|
echo "<tr>";
|
|
|
|
|
|
echo "<td>" . $wiersz["Procesor"] . "</td>";
|
|
echo "<td>" . $wiersz["Plyta_Glowna"] . "</td>";
|
|
echo "<td>" . $wiersz["Pamiec_Ram"] . "</td>";
|
|
echo "<td>" . $wiersz["Dysk"] . "</td>";
|
|
echo "<td>" . $wiersz["Karta_Graficzna"] . "</td>";
|
|
|
|
echo "</tr>";
|
|
|
|
|
|
}
|
|
echo "</table>";
|
|
echo "<br>";
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
else {
|
|
echo "Nie ma nic w bazie danych";
|
|
|
|
}
|
|
|
|
|
|
|
|
$wynik = $conn->query("SELECT * FROM uzytkownicy WHERE Id = 3 ");
|
|
|
|
echo "<h1>Informacje o uzytkowniku: </h1>";
|
|
|
|
if($wynik->num_rows > 0){
|
|
|
|
echo "<table style='border-spacing: 10px; border-collapse: collapse;' border='3'>";
|
|
echo "<tr>";
|
|
echo "<th>Imie</th>";
|
|
echo "<th>Nazwisko</th>";
|
|
echo "<th>Data wydania</th>";
|
|
echo "<th>Data zakonczenia leasingu</th>";
|
|
echo "<th>Dzial</th>";
|
|
echo "</tr>";
|
|
|
|
|
|
|
|
while( $wiersz = $wynik->fetch_assoc() ){
|
|
echo "<tr>";
|
|
|
|
echo "<td>" . $wiersz["Imie"] . "</td>";
|
|
echo "<td>" . $wiersz["Nazwisko"] . "</td>";
|
|
echo "<td>" . $wiersz["Data_wydania"] . "</td>";
|
|
echo "<td>" . $wiersz["Data_zak_lea"] . "</td>";
|
|
echo "<td>" . $wiersz["Dzial"] . "</td>";
|
|
|
|
|
|
echo "</tr>";
|
|
|
|
|
|
}
|
|
echo "</table>";
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
else {
|
|
echo "Nie ma nic w bazie danych";
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$conn->close();
|
|
|
|
?></span>
|
|
<p>
|
|
<br />
|
|
<a href="#">Klik</a>
|
|
<a href="#" class="margin1">OK</a>
|
|
</p>
|
|
|
|
|
|
</div>
|
|
<div id="footer">
|
|
<p>© Wszelkie prawa zastrzeżone. <br /> Projekt: Mikołaj Wojdyło s439508</a></p>
|
|
</div>
|
|
</body>
|
|
</html>
|
|
|
|
</body>
|