Projects\n";
echo "\t\t\t
\n";
foreach($projects as $project){
$lines = file("projects/$project","r");
preg_match("/(.*)<\/h2>/",$lines[0],$matches);
$abstract = substr($project,0,strlen($project)-5);
echo "\t\t\t\t
- $matches[1]
\n";
}
echo "\t\t\t
\n";
# echo "\t\t\tTutorials
\n";
# echo "\t\t\t\n";
# foreach($tutorials as $tutorial){
# $lines = file("projects/$tutorial","r");
# preg_match("/(.*)<\/h2>/",$lines[0],$matches);
# $abstract = substr($tutorial,0,strlen($tutorial)-5);
# echo "\t\t\t\t
- $matches[1]
\n";
# }
# echo "\t\t\t
\n";
echo "\t\t\t\n";
echo "\t\t\t\tView all projects\n";
echo "\t\t\t
\n";
/*
* insert project or tutorial abstract(s)
*/
if(isset($_GET)){
$abstract = $_GET['abstract'];
if($abstract == "all"){
foreach($projects as $project){
$lines = file("projects/$project","r");
echo "\t\t\t\n";
foreach($lines as $line){
echo "\t\t\t\t$line";
}
echo "\t\t\t
\n";
}
foreach($tutorials as $tutorial){
$lines = file("projects/$tutorial","r");
echo "\t\t\t\n";
foreach($lines as $line){
echo "\t\t\t\t$line";
}
echo "\t\t\t
\n";
}
}
else{
if(is_readable("projects/".$abstract.".html")){
$lines = file("projects/$abstract.html","r");
echo "\t\t\t\n";
foreach($lines as $line){
echo "\t\t\t\t$line";
}
echo "\t\t\t
\n";
}
}
}
$timestamp = date("D, M d, Y H:i:s", filemtime(__FILE__))." by ".get_current_user();
include "foot.html";
?>