$query = "Select * From ExStudents ORDER BY Surname"; $result = mysql_query($query); while ($row = mysql_fetch_array($result)) { $queryOnline = "SELECT * FROM ExStudentDetails WHERE ExStudentID = '$row[ExStudentID]'"; $resultOnline = mysql_query($queryOnline); //$rowOnline = mysql_fetch_array($resulOnline); $rsPub = mysql_fetch_array($resultOnline); $pub = $rsPub["StatusID"]; //echo $queryOnline . "
"; //echo $pub . "
"; if ($pub == 2) { if ( $id == $row[ExStudentID]) { echo "— $row[Name] $row[Surname]
"; }else{ echo "$row[Name] $row[Surname]
"; } } } ?>
//-- We need to build the image gallery for this student
$GalQuery = "SELECT * FROM ExStudentImages " .
"INNER JOIN ExStudentImageDetails ON ExStudentImageDetails.ExStudentImageID = ExStudentImages.ExStudentImageID " .
"WHERE ExStudentImages.ExStudentID = $id AND ExStudentImageDetails.LangID=$intLangID";
If ($resultExStGal = mysql_query($GalQuery,$db)) :
//-- Check to see if we have an imageID (user has selected an image from the gallery)
If(is_Numeric($intExStudentImageID)) :
While ($rs = mysql_fetch_array($resultExStGal)) :
If($intExStudentImageID == $rs["ExStudentImageID"]) :
//- Get the individual Image and movefirst in RS
$szImageFileMed = $rs["ImageFileMed"];
$szDescription = $rs["Description"];
mysql_data_seek($resultExStGal,0);
break;
EndIf;
EndWhile;
EndIf;
Else:
echo mysql_error($db);
echo "
$GalQuery"; EndIf; Else: echo mysql_error($db); echo "
$Query"; EndIf; ?>
&id=&intExStudentImageID=">
" width="50" height="40" border="0" alt="
Clicca per ingrandire il progetto
Click to enlarge
Click to enlarge
" >
Clicca per ingrandire il progetto Click to enlarge Click to enlarge
"") : ?>
"") :?>
$GalQuery"; EndIf; Else: echo mysql_error($db); echo "
$Query"; EndIf; ?>
&id=&intExStudentImageID=">
Clicca per ingrandire il progetto Click to enlarge Click to enlarge
"") : ?>