|
include ("functions.php3");
$mysql = sql_init ();
echo "how to use If you want to go back to the list of products corresponding to your query, please click the "back" button of your browser.\n";
?>
|
if ( $f_system ) {
$query = "SELECT s.stempel AS stempel, s.name AS name, s.authors AS authors, s.institute AS institute, s.description AS description, s.abstract AS abstract, s.url AS url, s.ftp AS ftp, s.email AS email, s.waehrung AS waehrung, s.required AS required FROM system s WHERE s.id = $f_system AND s.status = 1";
$result = mysql_query($query,$mysql);
echo mysql_error();
@$row = mysql_fetch_array($result);
$stempel = $row[stempel];
echo "\n";
echo "| " . $row[name] . " | \n";
echo "| | \n";
echo "| description: " . $row[description] . " | \n";
echo "| | \n";
echo " | \n";
if ( $row[authors] ) {
echo "| authors | | $row[authors] | \n";
}
if ( $row[institute] ) {
echo "| affiliation | | $row[institute] | \n";
}
if ( $row[url] ) {
echo "| homepage | | visit (in new window) | \n";
}
if ( $row[ftp] && $row[ftp] != "ftp://" ) {
echo "| ftp-location | | visit (in new window) | \n";
}
if ( $row[email] ) {
echo "| contact-email | | $row[email] | \n";
}
if ( $row[required] ) {
echo "| required software | | $row[required] | \n";
}
echo "| | ";
echo " | \n";
if ( $row[waehrung] ) {
$query2 = "SELECT name FROM waehrung WHERE id = $row[waehrung]";
$result2 = mysql_query($query2,$mysql);
echo mysql_error();
@$row2 = mysql_fetch_array($result2);
$waehrung = $row2[name];
}
$query = "SELECT DISTINCT d.type AS name FROM docu d, system_docu sd WHERE sd.docu_id = d.id AND sd.system_id = $f_system";
$result = mysql_query($query,$mysql);
echo mysql_error();
if ( mysql_affected_rows() ) {
echo "| documentation | | ";
$i = 0;
while ( @$row = mysql_fetch_array($result) ) {
if ( $i > 0 ) {
echo ", ";
}
echo "$row[name]";
$i++;
}
echo " | \n";
}
$query = "SELECT DISTINCT l.name AS name FROM language l, system_language sl WHERE sl.language_id = l.id AND sl.system_id = $f_system";
$result = mysql_query($query,$mysql);
echo mysql_error();
if ( mysql_affected_rows() ) {
echo "| supported languages | | ";
$i = 0;
while ( @$row = mysql_fetch_array($result) ) {
if ( $i > 0 ) {
echo ", ";
}
echo "$row[name]";
$i++;
}
echo " | \n";
}
$query = "SELECT DISTINCT o.type AS name FROM os o, system_os so WHERE so.os_id = o.id AND so.system_id = $f_system";
$result = mysql_query($query,$mysql);
echo mysql_error();
if ( mysql_affected_rows() ) {
echo "| platforms | | ";
$i = 0;
while ( @$row = mysql_fetch_array($result) ) {
if ( $i > 0 ) {
echo ", ";
}
echo "$row[name]";
$i++;
}
echo " | \n";
}
$query = "SELECT DISTINCT s.type AS name FROM software s, system_software ss WHERE ss.software_id = s.id AND ss.system_id = $f_system";
$result = mysql_query($query,$mysql);
echo mysql_error();
if ( mysql_affected_rows() ) {
echo "| distribution | | ";
$i = 0;
while ( @$row = mysql_fetch_array($result) ) {
if ( $i > 0 ) {
echo ", ";
}
echo "$row[name]";
$i++;
}
echo " | \n";
}
$query = "SELECT DISTINCT m.name AS mainsectionname, s.name AS name , s.id AS id, ss.section_id AS sid, s.mainsection_id AS ms FROM section s, system_section ss, mainsection m WHERE ss.section_id = s.id AND ss.system_id = $f_system AND s.mainsection_id = m.id ORDER BY mainsectionname, name";
$result = mysql_query($query,$mysql);
echo mysql_error();
if ( mysql_affected_rows() ) {
echo "| sections | | ";
$i = 0;
while ( @$row = mysql_fetch_array($result) ) {
if ( $i > 0 ) {
echo ", ";
}
echo "$row[name]";
$i++;
}
echo " | \n";
}
$status[1] = "";
$status[2] = "to negotiate";
$status[3] = "free";
$query = "SELECT DISTINCT academic_s, multiple_s, commercial_s, academic_p, multiple_p, commercial_p FROM license WHERE system_id = $f_system";
$result = mysql_query($query,$mysql);
echo mysql_error();
if ( mysql_affected_rows() ) {
@$row = mysql_fetch_array($result);
echo "| | ";
echo " | \n";
echo "| pricing | ";
echo "| | ";
if ( $row[academic_s] ) {
echo "| academic | | " . $status[$row[academic_s]];
if ( $row[academic_p] ) {
if ( $row[academic_s] != 1 ) {
echo ", ";
}
echo "$waehrung $row[academic_p],--";
}
echo " | ";
}
if ( $row[multiple_s] ) {
echo "| multiple user | | " . $status[$row[multiple_s]];
if ( ( $row[multiple_s] == 1 ) && ( $row[multiple_p] ) ) {
if ( $row[multiple_s] != 1 ) {
echo ", ";
}
echo "$waehrung $row[multiple_p],--";
}
echo " | ";
}
if ( $row[commercial_s] ) {
echo "| commercial | | " . $status[$row[commercial_s]];
if ( ( $row[commercial_s] == 1 ) && ( $row[commercial_p] ) ) {
if ( $row[commercial_s] != 1 ) {
echo ", ";
}
echo "$waehrung $row[commercial_p],--";
}
echo " | ";
}
}
echo " | \n";
// hier kommt das Datum der letzten Ueberpruefung (stempel) hin
$stempel_format = substr ($stempel, 6,2) . "." . substr ($stempel, 4,2) . "." . substr ($stempel, 0,4);
echo "| last verified: $stempel_format | \n";
echo "| | \n";
echo " ";
} else {
echo "error";
}
?>
|