$query1 ="select * from tovar join book on tovar.products_id = book.id";
$result1 = mysqli_query($link, $query1) or die("Ошибка " . mysqli_error($link));
while($row1 = mysqli_fetch_assoc($result1)){
echo '<li><a href="'.$row1["tovar"].'" target="_blank">'.$row1["many"].'</a></li>';
}
$query1 ="select * from tovar join book on tovar.products_id = book.id";
$result1 = mysqli_query($link, $query1) or die("Ошибка " . mysqli_error($link));
while($row1 = mysqli_fetch_assoc($result1)){
echo '<li><a href="'.$row1["tovar"].'" target="_blank">'.$row1["many"].'</a></li>';
}
<form>
<div class="form-group">
<label>Стоимость</label>
<input type="text" class="form-control3" id="summa" value="1000" onchange="calc()" >
</div>
<div class="form-group">
<label for="amount-sample-4">Страна:</label>
<div class="form-check">
<input class="form-check-input" type="radio" name="exampleRadios" id="rossia" value="0" onchange="calc()" checked>
<label class="form-check-label" for="rossia">
Россия
</label>
</div>
<div class="form-check">
<input class="form-check-input" type="radio" name="exampleRadios" id="drstrana" value="600" onchange="calc()" checked>
<label class="form-check-label" for="drstrana">
Другая страна
</label>
</div>
</div>
<div class="form-group">
<label for="name-sample-4">Адрес:</label>
<div>
<input id="name-sample-4" required="" placeholder="" class="form-control" type="text" value="Walter" size="30">
</div>
</div>
<div class="form-group">
<label for="amount-sample-4">Доставка:</label>
<div class="form-check">
<input class="form-check-input" type="radio" name="exampleRadios1" id="pochta" value="600" onchange="calc()" checked>
<label class="form-check-label" for="pochta">
Почта России
</label>
</div>
<div class="form-check">
<input class="form-check-input" type="radio" name="exampleRadios1" id="kurier" value="0" onchange="calc()" checked>
<label class="form-check-label" for="kurier">
Курьерская доставка
</label>
</div>
</div>
<br/>
<div>Стоимость дизайна сайта: <span id="result">0</span> руб.</div>
</form>
<?php
$link = mysqli_connect($db_host, $db_user, $db_password, $db_database)
or die("Ошибка " . mysqli_error($link));
$query ="SELECT * FROM blog ORDER BY id ";
$result = mysqli_query($link, $query) or die("Ошибка " . mysqli_error($link));
if (mysqli_num_rows($result) > 0)
{
$row = mysqli_fetch_array($result);
do
{
$img_pathh = 'uploads_images/'.$row["image"];
list($width, $height) = getimagesize($img_pathh);
$ratioh = $max_height/$height;
$ratiow = $max_width/$width;
$ratio = min($ratioh, $ratiow);
$width = intval($ratio*$width);
$height = intval($ratio*$height);
echo '
<div class="col-md-4 editContent">
<div class="blog">
<div class="blogimg"><img src="'.$img_pathh.'" /></div>
<div class="blogtext">
<p>'.$row["zagalovok"].'</p>
<a href="article.php?id='.$row["id"].'">Читать <img src="img/strek2.png"/></a>
</div>
</div>
</div>
';
}
while ($row = mysqli_fetch_array($result));
}
?>