<?php
if (($_GET['user']) && ($_GET['tutorial'])) {
$filename = $_GET['user'].$_GET['tutorial'].".txt";
if (file_exists("tutorialprofiles/".$_GET['user'].".html")) {
if (file_exists("tutorials/".$filename)) include("tutorials/".$filename);
else {
?><div align="center"><b>Sorry the tutorial u specified does not exist</b></div>
<?php include("tutorialprofiles/".$_GET['user'].".html");
}
}
else {
?><center><b>Sorry there was no user by the name of <?php echo $_GET['user']; ?></center></b>
<?php include("tutrubric.html");
}
}
elseif ((!$_GET['user']) && ($_GET['tutorial'])) {
?><b>Sorry, the url you entered doesn't link to any user.</b><br>
<?php include("tutrubric.html");
}
elseif (($_GET['user']) && (!$_GET['tutorial'])) {
if (file_exists("tutorialprofiles/".$_GET['user'].".html")) include("tutorialprofiles/".$user.".html");
else {
?><center><b>Sorry there was no user by the name of <?php echo $_GET['user']; ?></center></b>
<?php include("tutrubric.html");
}
}
else include("tutrubric.html");
?>