first commit
This commit is contained in:
commit
d5255ea7fd
0
american.php
Normal file
0
american.php
Normal file
BIN
crested.jpg
Normal file
BIN
crested.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 57 KiB |
0
crested.php
Normal file
0
crested.php
Normal file
BIN
peruwianka.jpg
Normal file
BIN
peruwianka.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 68 KiB |
69
peruwianka.php
Normal file
69
peruwianka.php
Normal file
@ -0,0 +1,69 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="PL">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<title>Hodowla świnek morskich</title>
|
||||||
|
<link rel="stylesheet" href="styl.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<header>
|
||||||
|
<h1>Hodowla świnek morskich - zamów świnkowe maluszki</h1>
|
||||||
|
</header>
|
||||||
|
<nav>
|
||||||
|
<a href="peruwianka.php">Rasa Peruwianka</a>
|
||||||
|
<a href="american.php">Rasa American</a>
|
||||||
|
<a href="crested.php">Rasa Crested</a>
|
||||||
|
</nav>
|
||||||
|
<aside>
|
||||||
|
<h3>Poznaj wszystkie rasy świnek morskich</h3>
|
||||||
|
<ol>
|
||||||
|
<?php
|
||||||
|
$mysqli = mysqli_connect('localhost', 'root', '', 'hodowla');
|
||||||
|
$lista = mysqli_query($mysqli, "SELECT rasa FROM rasy");
|
||||||
|
while($row = mysqli_fetch_row($lista)){
|
||||||
|
echo "<li>" . $row[0] . "</li>";
|
||||||
|
}
|
||||||
|
mysqli_close($mysqli);
|
||||||
|
?>
|
||||||
|
</ol>
|
||||||
|
</aside>
|
||||||
|
<main>
|
||||||
|
<img src="peruwianka.jpg" alt="Świnka morska rasy peruwianka">
|
||||||
|
<?php
|
||||||
|
$mysqli = mysqli_connect('localhost', 'root', '', 'hodowla');
|
||||||
|
$skrypt2 = mysqli_query($mysqli, "SELECT DISTINCT data_ur, miot, rasa FROM rasy JOIN swinki ON rasy.id = rasy_id WHERE rasy.id = '1'");
|
||||||
|
while($rasa = mysqli_fetch_array($skrypt2)){
|
||||||
|
echo "<h2>Rasa: " . $rasa[2] . "</h2>";
|
||||||
|
}
|
||||||
|
|
||||||
|
$skrypt2 = mysqli_query($mysqli, "SELECT DISTINCT data_ur, miot, rasa FROM rasy JOIN swinki ON rasy.id = rasy_id WHERE rasy.id = '1'");
|
||||||
|
while($rasa = mysqli_fetch_array($skrypt2)){
|
||||||
|
echo "<p>Data urodzenia: " . $rasa[0] . "</p>";
|
||||||
|
}
|
||||||
|
|
||||||
|
$skrypt2 = mysqli_query($mysqli, "SELECT DISTINCT data_ur, miot, rasa FROM rasy JOIN swinki ON rasy.id = rasy_id WHERE rasy.id = '1'");
|
||||||
|
while($rasa = mysqli_fetch_array($skrypt2)){
|
||||||
|
echo "<p>Oznaczenie miotu: " . $rasa[1] . "</p>";
|
||||||
|
}
|
||||||
|
mysqli_close($mysqli);
|
||||||
|
?><hr>
|
||||||
|
<h2>Świnki w tym miocie</h2>
|
||||||
|
<?php
|
||||||
|
$mysqli = mysqli_connect('localhost', 'root', '', 'hodowla');
|
||||||
|
$skrypt3 = mysqli_query($mysqli, "SELECT imie, cena, opis FROM swinki WHERE rasy_id = '1'");
|
||||||
|
while($trojka = mysqli_fetch_array($skrypt3)){
|
||||||
|
echo "<h3>" . $trojka[0] . " - " . $trojka[1] . "zl</h3><p>" . $trojka[2] . "</p>";
|
||||||
|
}
|
||||||
|
|
||||||
|
mysqli_close($mysqli);
|
||||||
|
?>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
<footer>
|
||||||
|
<p>Stronę wykonał: CHUJ DUPA CIPA</p>
|
||||||
|
</footer>
|
||||||
|
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
55
styl.css
Normal file
55
styl.css
Normal file
@ -0,0 +1,55 @@
|
|||||||
|
html {
|
||||||
|
font-family: Helvetica;
|
||||||
|
}
|
||||||
|
|
||||||
|
header, footer{
|
||||||
|
background-color: saddlebrown;
|
||||||
|
color: white;
|
||||||
|
text-align: center;
|
||||||
|
padding: 7px;
|
||||||
|
}
|
||||||
|
|
||||||
|
nav {
|
||||||
|
background-color: peru;
|
||||||
|
width: 80%;
|
||||||
|
height: 40px;
|
||||||
|
padding-top: 20px;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
main {
|
||||||
|
width: 80%;
|
||||||
|
height: 700px;
|
||||||
|
font-size: 120%;
|
||||||
|
overflow: auto;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
aside {
|
||||||
|
background-color: peru;
|
||||||
|
color: white;
|
||||||
|
width: 20%;
|
||||||
|
height: 760px;
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
footer {
|
||||||
|
clear: both;
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: #ddd;
|
||||||
|
padding-left: 90px;
|
||||||
|
font-size: 140%;
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
a:hover{
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
img{
|
||||||
|
float: left;
|
||||||
|
margin: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user