Хранилища Subversion ant

Редакция

Редакция 471 | Авторство | Сравнить с предыдущей | Последнее изменение | Открыть журнал | Скачать | RSS

<?php

include "inc/header.htm";

require_once 'DB.php';

$dsn = 'sqlite:///set.db?mode=0777';

$db_set =& DB::connect($dsn);
if (PEAR::isError($db_set)) {
    die($db_set->getMessage());
}

$distr = abs(intval($_GET["d"]));

if($distr==0) {
        $distrs =& $db_set->query("SELECT * FROM distrs");
        echo "<form name='distrch' method='get' action='index.php'>";
        echo "<b>Дистрибутив:</b><br>";
        while ($distrs->fetchInto($info_distrs,DB_FETCHMODE_ASSOC)) {
            echo "<input type='radio' name='d' value='".$info_distrs['id']."'> ".$info_distrs['distr']."<br>\n";
        }
        echo "<p><input type='submit' value='Выбрать'>";
        echo "</form>";
}
else {
        $vers =& $db_set->query("SELECT * FROM vers WHERE distr_id=".$distr);
        echo "<form name='verch' method='get' action='shower.php'>";
        echo "<b>Версия:</b><br>";
        while ($vers->fetchInto($info_vers,DB_FETCHMODE_ASSOC)) {
            echo "<input type='radio' name='d' value='".$info_vers['id']."'> ".$info_vers['vernum']." ".$info_vers['codename']."<br>\n";
        }
        echo "<p><input type='submit' value='Выбрать'>";
        echo "</form>";
}

include "inc/footer.htm";
?>