[cvs] / gkbweb / htdocs / specialized.php  

cvs: gkbweb/htdocs/specialized.php

File: [cvs] / gkbweb / htdocs / specialized.php (download) (as text)
Revision: 1.9, Wed Mar 21 22:12:40 2007 UTC (6 years, 2 months ago) by tobias
Branch: MAIN
CVS Tags: HEAD
Changes since 1.7: +53 -100 lines
lots of updates

<?php
    
if (!isset($category))
        
$category="";

    include(
$DOCUMENT_ROOT."/shared/inc/global.inc");
    
$page "specialized-$category";
    
$title "All Specialized Kernels";
    
    
$host "www.ppckernel.org";
    
    if (!(
$dbh dbconnect())) {
        echo 
"FATAL ERROR: dbconnect() failed.";
        exit;
    }
    if (
$q mysql_query("select name, descr from buildcategories where safename='$category'")) {
        if (
$r mysql_fetch_object($q)) {
            
$title $r->name;
            
$descr $r->descr;
        }
    }
        
    include(
$layout_top);
?>
<h2><?php echo $title ?></h2>
<?php
    
if (isset($descr)) {
        echo 
"<p>$descr</p>";
    }

    if (!empty(
$category))
        
$catclause="category='$category' and";
    else
        
$catclause="";

    if (
$q mysql_query("select name, safename, fullname, description, patchfile, configfile,configpath from builds, mastertrees where $catclause (configpath != '' or configfile != \"\" or patchfile != \"\") and status!='disabled' and mastertrees.name=builds.mastertree order by fullname"$dbh)) {
        if (
mysql_num_rows($q) > 0) {
            echo 
"<table border=\"0\" cellpadding=\"5\" cellspacing=\"0\">\n";
            
$i=0;
            while (
$r mysql_fetch_object($q)) {
                
$i++;
                
showkernel($r->name$r->safename$r->fullname$r->description$r->patchfile$r->configfile$r->configpath);
                if (
$i mysql_num_rows($q))
                    echo 
"<tr><td colspan=\"2\">&nbsp;</td></tr>\n";
            }
            echo 
"</table>\n";            
        } else {
            echo 
"<p>No kernels found.</p>\n";
        }
    }
        
    
    include(
$layout_tail);
?>

Tobias McNulty

Powered by ViewCVS 1.0-dev
(Powered by ViewCVS)

ViewCVS and CVS Help