$value) { $dvp=$dvp_tab[$section_id]["dvp"]; foreach( $dvp as $dvp_id => $value) { if( $dvp_id == $dvp_id_lookup) { return $section_id; } } } return ""; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_get_name( $dvp_id_lookup) { global $dvp_tab; foreach( $dvp_tab as $section_id => $value) { $dvp=$dvp_tab[$section_id]["dvp"]; foreach( $dvp as $dvp_id => $value) { if( $dvp_id == $dvp_id_lookup) { return $dvp[$dvp_id]["name"]; } } } return ""; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_get_reqby( $dvp_id_lookup) { global $dvp_tab; foreach( $dvp_tab as $section_id => $value) { $dvp=$dvp_tab[$section_id]["dvp"]; foreach( $dvp as $dvp_id => $value) { $depend=$dvp[$dvp_id]["depend"]; if( $depend != "") { foreach( $depend as $depend_id) { if( $depend_id == $dvp_id_lookup) { $reqby[]=$dvp_id; } } } } } return $reqby; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_main_header( $name) { $page_name="$name"; $page_title="$page_name !"; global $dvp_tab; global $dvp_header; global $dvp_keywords; $keywords="$dvp_keywords"; foreach( $dvp_tab as $section_id => $value) { foreach( $dvp_tab[$section_id]["dvp"] as $dvp_id => $value) { $keywords="$keywords,$dvp_id"; } } include "$dvp_header"; echo " $page_name

$page_title

Rx3.Org Main Page

"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_main_body( $dvp_tab) { global $dvp_download_http_url; global $dvp_download_ftp_url; global $dvp_cvsweb_url; echo "



"; foreach( $dvp_tab as $section_id => $value) { $section_name=$dvp_tab[$section_id]["name"]; $dvp=$dvp_tab[$section_id]["dvp"]; echo "

$section_name



"; } echo "
"; echo "Rx3 Free Software Development HTTP download page   "; echo "Rx3 Free Software Development FTP download page   "; echo "Rx3 Free Software CVS Web
"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_main_page() { global $dvp_tab; dvp_main_header( "Rx3 Free Software Development Main Page"); dvp_main_body( $dvp_tab); dvp_footer(); } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_header( $id, $name, $summary, $curver) { $page_name="$name Home Page"; $page_title="$page_name !"; global $dvp_url; global $dvp_header; global $dvp_keywords; $keywords="$dvp_keywords,$id"; include "$dvp_header"; echo " $page_name

$page_title

$summary

$curver

Rx3.Org Main Page  /  Rx3 Free Software Development Main Page

"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_body( $id, $name, $description, $depend, $freshmeat, $curver) { global $dvp_download_http_url; global $dvp_download_ftp_url; global $dvp_cvsweb_url; global $dvp_freshmeat_url; echo "



$description

"; if( $depend != "") { echo "

Dependend on:

"; foreach( $depend as $dep_id) { $dep_name=dvp_get_name( $dep_id); echo "$dep_name   "; } } $reqby=dvp_get_reqby( $id); if( $reqby != "") { echo "

Required by:

"; foreach( $reqby as $dep_id) { $dep_name=dvp_get_name( $dep_id); echo "$dep_name   "; } } echo "

"; if( $curver != "") { $cmd="tar xOzf download/$id/$id-$curver.src.tgz $id-$curver/ReleaseNotes.txt|awk 'BEGIN {go=0; skip=0;} /---------/ {go+=1; skip=1} /^$/ {if(go > 0) go+=1;} {if( ( skip != 1) && ( go > 0) && ( go < 4)) { print $0;} else skip=0;}'"; exec( $cmd, $rn_tab); echo "



Last Release Notes:   $rn_tab[0]
"; echo "
";
    for( $i = 1; $i < count($rn_tab); $i++)
    {
      echo "$rn_tab[$i]\n";
    }

    echo "    
"; } echo"
"; if( $curver != "") { echo "$name release notes page   "; echo "$name readme page   "; } echo "$name HTTP download page   "; echo "$name FTP download page   "; echo "$name CVS Web"; if( $freshmeat == "yes") { echo "   $name FreshMeat page "; } echo "
"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_footer() { global $dvp_myname; global $dvp_myver; global $dvp_footer; global $time_start; include "$dvp_footer"; $time_stop = microtime_float(); $time_elaps = intval( ( $time_stop - $time_start) * 1000) / 1000; echo "

"; echo "
Page generated in $time_elaps seconds by $dvp_myname V $dvp_myver
"; echo" "; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_page( $dvp_id, $dvp_name, $dvp_summary, $dvp_description, $depend, $dvp_freshmeat) { $cmd="ls download/$dvp_id/$dvp_id*.src.tgz | sed -e 's/.*$dvp_id-//' -e 's/.src.tgz//'"; $dvp_curver=exec($cmd); dvp_header( $dvp_id, $dvp_name, $dvp_summary, $dvp_curver); dvp_body( $dvp_id, $dvp_name, $dvp_description, $depend, $dvp_freshmeat, $dvp_curver); dvp_footer(); } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_rn_header( $id, $name, $curver) { $page_name="$name Release Notes Page"; $page_title="$page_name"; global $dvp_url; global $dvp_header; global $dvp_keywords; $keywords="$dvp_keywords,$id, $id release notes"; include "$dvp_header"; echo " $page_name

$page_title

$curver

Rx3.Org Main Page  /  Rx3 Free Software Development Main Page  /  $name Home Page

"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_rn_body( $id, $name, $curver) { if( $curver != "") { $cmd="tar xOzf download/$id/$id-$curver.src.tgz $id-$curver/ReleaseNotes.txt"; exec( $cmd, $rn_tab); echo "
";
    for( $i = 1; $i < count($rn_tab); $i++)
    {
      echo "$rn_tab[$i]\n";
    }
  }

  echo "    
"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_rn_page( $dvp_id, $dvp_name) { $cmd="ls download/$dvp_id/$dvp_id*.src.tgz | sed -e 's/.*$dvp_id-//' -e 's/.src.tgz//'"; $dvp_curver=exec($cmd); dvp_rn_header( $dvp_id, $dvp_name, $dvp_curver); dvp_rn_body( $dvp_id, $dvp_name, $dvp_curver); dvp_footer(); } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_rm_header( $id, $name, $curver) { $page_name="$name Read Me Page"; $page_title="$page_name"; global $dvp_url; global $dvp_header; global $dvp_keywords; $keywords="$dvp_keywords,$id, $id release notes"; include "$dvp_header"; echo " $page_name

$page_title

$curver

Rx3.Org Main Page  /  Rx3 Free Software Development Main Page  /  $name Home Page

"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_rm_body( $id, $name, $curver) { if( $curver != "") { $cmd="tar xOzf download/$id/$id-$curver.src.tgz $id-$curver/ReadMe.txt"; exec( $cmd, $rm_tab); echo "
";
    for( $i = 1; $i < count($rm_tab); $i++)
    {
      echo "$rm_tab[$i]\n";
    }
  }

  echo "    
"; } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ function dvp_rm_page( $dvp_id, $dvp_name) { $cmd="ls download/$dvp_id/$dvp_id*.src.tgz | sed -e 's/.*$dvp_id-//' -e 's/.src.tgz//'"; $dvp_curver=exec($cmd); dvp_rm_header( $dvp_id, $dvp_name, $dvp_curver); dvp_rm_body( $dvp_id, $dvp_name, $dvp_curver); dvp_footer(); } /*--------------------------------------------------------------------------------------------------------------------*/ /* */ /*--------------------------------------------------------------------------------------------------------------------*/ if( $_GET["dvp"] == "") { dvp_main_page( $dvp_tab); } else { $dvp_id=$_GET["dvp"]; $section_id=dvp_get_section( $dvp_id); $dvp_name=$dvp_tab[$section_id]["dvp"][$dvp_id]["name"]; if( $_GET["rn"] == "yes") { dvp_rn_page( $dvp_id, $dvp_name); } else { if( $_GET["rm"] == "yes") { dvp_rm_page( $dvp_id, $dvp_name); } else { $dvp_summary=$dvp_tab[$section_id]["dvp"][$dvp_id]["summary"]; $dvp_description=$dvp_tab[$section_id]["dvp"][$dvp_id]["description"]; $dvp_depend=$dvp_tab[$section_id]["dvp"][$dvp_id]["depend"]; $dvp_freshmeat=$dvp_tab[$section_id]["dvp"][$dvp_id]["freshmeat"]; dvp_page( $dvp_id, $dvp_name, $dvp_summary, $dvp_description, $dvp_depend, $dvp_freshmeat); } } } ?>