——————download.php—————
<?php
include "config.php";
echo "<br><br>";
if ($id!=0)
{$ath = mysql_query("select * from books where Code=$id;");};
echo "<form action='mail1.php' method=POST>";
echo "<table border=0>";
echo "<td><IMG src='pictures/01.jpg' border=0></td>";
echo "<tr><td>для загрузки книги ведите свой e-mail:</td></tr>";
echo "<td><input type='text' maxlength=50 size=30 name='email'></td>";
echo "<td><input type='submit' value='Загрузка'></td>";
echo "</table>";
if ($ath)
{
echo "<br><br><table border=1 width='100%' bgcolor=ffffcc>";
echo "<tr><td>Название</td><td>Автор</td><td>Описание</td><td>Кафедра</td><td>Издательство</td><td>Год</td><td>Скачать</td></tr>";
while($news = mysql_fetch_array($ath))
{
echo "<tr><td><font size=3>".$news['Name_book']." </font></td>";
echo "<td><font size=3>".$news['Avtor']." </font></td>";
echo "<td align=right><font size=3>".$news['Description']." </font></td>";
echo "<td align=right><font size=3>".$news['Pulpit']." </font></td>";
echo "<td align=right><font size=3>".$news['Publishers']." </font></td>";
echo "<td align=right><font size=3>".$news['Year']." </font></td>";
echo "<td align=center><font size=2>".$news['Download']." </font></td></tr>";
}
echo "</table>";
}
echo "</form>";
?>
——————mail1.php—————
<?php
$email=$_POST['email'];
echo "<table>";
echo "<tr><a href='mailto:$email?subject=REPORT'>Отправить</a></tr></table>";
?>