Parse error: syntax error, unexpected $end in /home/wmsumo/public_html/student_profile.php on line 394
IN THIS PROGRAMME....
<?php
@session_start();
include('mysql.php');
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="css/style.css"/>
</head>
<body>
<div class="overall_container">
<div class="div_head" style="border-bottom: 0px solid red;"><img src="images/header.jpg"/></div>
<div class="div_menu">
<div class="div_menu_right">
<?php
$id = $_GET['user'];
$query = "SELECT * from student where idnumber='$id'";
$result = mysql_query($query);
while($row=mysql_fetch_array($result))
{
extract($row);
@$userid = $row[student_id];
echo "Logged in as $row[firstname] $row[lastname],";
}
?>
<a href="index.php">Log out?</a>
</div>
</div>
<div class="body_container" style="margin-top: 0px;">
<div class="in_menu">
<?php
$id = $_GET['user'];
$query = "SELECT * from studentaccess where student_id='$id'";
$result = mysql_query($query);
while($row=mysql_fetch_array($result))
{
extract($row);
@$userid = $row[student_id];
echo "<a style='margin-left: 15px;' href='student_profile.php?user=$userid''>Home</a> |
<a href='#.php'>Grade Information and Inquiry System via SMS</a> |
<a href='#.php'>Online Billing System</a> |
<a href='student_choice.php?login=$userid'>Exit</a>";
}
?>
<?php
$id = $_GET['user'];
$query = "SELECT * from studentaccess where username='$id'";
$result = mysql_query($query);
while($row=mysql_fetch_array($result))
{
extract($row);
@$userid = $row[student_id];
echo "<font style='float: right;'>
Change <a href='student_changepass2.php?id=$userid'>Password</a> |
<a href='student_changephoto.php?id=$userid'>Photo</a>
</font> ";
}
?>
</div>
<table border="0" style="border-bottom: 1px solid #00FF00; width: 100%; margin-top: 20px; margin-bottom: 20px;" align="center">
<td>
<table border="0" style="width: 29%; float: left;">
<td valign="top" style="margin-bottom: 10px;">
<?php
$id = $_GET['user'];
$query = "SELECT * from studentaccess where student_id='$id'";
$result = mysql_query($query);
while($row=mysql_fetch_array($result))
{
extract($row);
@$userid = $row[student_id];
$sqlquery = "SELECT * from student where idnumber='$userid'";
$sqlresult = mysql_query($sqlquery) or die (mysql_error());
while($row1=mysql_fetch_array($sqlresult))
{
echo "<table border='0' style='width: 100%; background: maroon; border: 1px solid red; border-radius: 10px; box-shadow: 2px 2px 2px 2px #F6C9CC;'>
<tr><td colspan='2' style='color: #00FF00;' align='center'><img style='width: 150px; height: 120px; border: 1px solid white; margin-right: 20px;' src='images/logo.jpg'/></td></tr>
<tr><td class='label'>Student ID:</td><td class='td'>
08-8824
</td></tr>
<tr><td class='label'>Name:</td><td class='td'>$row1[firstname] $row1[middlename] $row1[lastname]</td></tr>
<tr><td class='label'>Address:</td><td class='td'>$row1[address]</td></tr>
<tr><td class='label'>Gender:</td><td class='td'>$row1[gender]</td></tr>
<tr><td class='label'>Birthdate:</td><td class='td'>$row1[birthdate]</td></tr>
<tr><td class='label'>Civil Status:</td><td class='td'>$row1[civilstatus]</td></tr>
<tr><td class='label'>Contact Number:</td><td class='td'>$row1[contactnumber]</td></tr>";
}
$sqlquery1 = "SELECT * from student_course where student_id='$userid'";
$sqlresult1 = mysql_query($sqlquery1) or die (mysql_error());
while($row2=mysql_fetch_array($sqlresult1))
{
echo "<tr><td class='label'>Course:</td><td class='td'>$row2[course_code]</td></tr></table>";
}
}
?>
<table border="0" style="width: 100%; margin-top: 20px; border: 1px solid lightgreen; background: maroon; box-shadow: 2px 2px 2px 2px #FFAEB9;" align="right">
<tr><td colspan="2" style="font-size: 18px; color: white; border: 1px solid white; font-weight: bold; background: red;" align="center">Examination Period Reminders</td></tr>
<tr><td class="label">First Unit Test:</td><td class="td">kanus.a to girl?</td></tr>
<tr><td class="label">Midterm Examination:</td><td class="td">kanus.a to girl?</td></tr>
<tr><td class="label">Second Unit Test:</td><td class="td">kanus.a to girl?</td></tr>
<tr><td class="label">Final Examination:</td><td class="td">kanus.a to girl?</td></tr>
<tr><td colspan="2" align="center">Please be guided accordingly!</td></tr>
</table>
</td>
</table>
<div style="width: 69%; float: right; border: 1px solid red; border-radius: 10px; background: brown; box-shadow: 2px 2px 2px 2px #FFAEB9; margin-right: 7px; margin-top: 3px;">
<div class="in_menu">
<?php
$id = $_GET['user'];
$query = "SELECT * from studentaccess where student_id='$id'";
$result = mysql_query($query);
while($row=mysql_fetch_array($result))
{
extract($row);
@$userid = $row[student_id];
echo "<a href='student_schedule.php?user=$userid'>View Student Schedule</a> | <a href='student_viewgrade.php?user=$userid'>View Student Final Grade</a>";
}
?>
</div>
<div class="in_menu" style="border: 0px solid lightgreen; text-decoration: underline;"><center><h3>Subjects Taken</h3></center></div>
<center>
<div class="search_style" style="box-shadow: inset 2px 2px 2px 2px #FFAEB9;">
<?php
$id = $_GET['user'];
echo "<form action='' method='POST'>";
?>
<table border="0" style="width: 95%; height: auto; margin-top: 16px;">
<tr>
<td>School Year</td>
<td>:</td>
<td>
<select name='schoolyear' class='input_box' style='width: 150px;'>
<option value=''>---School Year---</option>
<?php
$sy=date("Y",strtotime(now));
$num=$sy+1;
echo "<option value='$sy-$num'>$sy-$num</option>";
for($a=1;$a<=10;$a++)
{
$sy=$sy-1;
$num=$num-1;
echo "<option value='$sy-$num'>$sy-$num</option>";
}
?>
</select>
</td>
<td> </td>
<td>Semester</td>
<td>:</td>
<td>
<select name='semester' class="input_box" style="width: 150px;">
<option value=''>---Semester---</option>
<option value='First'>1st</option>
<option value='Second'>2nd</option>
<option value='Summer'>Summer</option>
</select>
</td>
</tr>
<tr>
<td>Year Level</td>
<td>:</td>
<td>
<select name='yearlevel' class='input_box' style='width: 150px;'>
<option value=''>---Year Level---</option>
<option value='I'>1st Year</option>
<option value='II'>2nd Year</option>
<option value='III'>3rd Year</option>
<option value='IV'>4th Year</option>
</select>
</td>
<td> </td>
<td colspan='3' align='right'>
<input type='submit' style='margin-right: 15px; border-radius: 1em 4em 1em 4em;' name='search' value='Search' class='submit'/>
</td>
</tr>
</table>
</form>
</div>
</center>
<table border="0" style="width: 97%; height: auto; margin-top: 20px; margin-bottom: 10px;" align="center">
<tr>
<th class="th"> Subject Code </th>
<th class="th"> Subject Description </th>
<th class="th"> Lab Unit </th>
<th class="th"> Lec Unit </th>
<th class="th"> Total Unit </th>
</tr>
<?php
if(isset($_POST['search']))
{
$year = $_POST['schoolyear'];
$sems = $_POST['semester'];
$lev = $_POST['yearlevel'];
$id = $_GET['user'];
$query="select * from student_class where student_id='$id'";
$result=mysql_query($query) or die(mysql_error());
$row=mysql_num_rows($result);
if($row!=0)
{
$query="select * from student_class where student_id='$id'";
$result=mysql_query($query) or die(mysql_error());
while($row=mysql_fetch_array($result))
{
extract($row);
$code=$row[subject_code];
$total=0;
if($year=="$row[schoolyear]" && $sems=="" && $lev=="")
{
$subjectquery="select * from subject where subject_id='$code'";
$result1=mysql_query($subjectquery) or die(mysql_error());
while($subjectrow=mysql_fetch_array($result1))
{
$newtotal=$tot;
extract($subjectrow);
echo "<tr style='background: maroon'>";
echo "<td class='td_c' align='center'>$subjectrow[subject_code]</td>";
echo "<td class='td_c' align='center'>$subjectrow[description]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lab_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lec_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[unit]</td>";
echo "</tr>";
$total=$newtotal+$subjectrow[unit];
$tot=$total;
}
}
else if($sems=="$row[semester]" && $year=="" && $lev=="")
{
$subjectquery="select * from subject where subject_id='$code'";
$result1=mysql_query($subjectquery) or die(mysql_error());
while($subjectrow=mysql_fetch_array($result1))
{
$newtotal=$tot;
extract($subjectrow);
echo "<tr style='background: maroon'>";
echo "<td class='td_c' align='center'>$subjectrow[subject_code]</td>";
echo "<td class='td_c' align='center'>$subjectrow[description]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lab_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lec_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[unit]</td>";
echo "</tr>";
$total=$newtotal+$subjectrow[unit];
$tot=$total;
}
}
else if($lev=="$row[yearlevel]" && $year=="" && $sems=="")
{
$subjectquery="select * from subject where subject_id='$code'";
$result1=mysql_query($subjectquery) or die(mysql_error());
while($subjectrow=mysql_fetch_array($result1))
{
$newtotal=$tot;
extract($subjectrow);
echo "<tr style='background: maroon'>";
echo "<td class='td_c' align='center'>$subjectrow[subject_code]</td>";
echo "<td class='td_c' align='center'>$subjectrow[description]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lab_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lec_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[unit]</td>";
echo "</tr>";
$total=$newtotal+$subjectrow[unit];
$tot=$total;
}
}
else if($sems=="$row[semester]" && $year=="$row[schoolyear]" && $lev=="")
{
$subjectquery="select * from subject where subject_id='$code'";
$result1=mysql_query($subjectquery) or die(mysql_error());
while($subjectrow=mysql_fetch_array($result1))
{
$newtotal=$tot;
extract($subjectrow);
echo "<tr style='background: maroon'>";
echo "<td class='td_c' align='center'>$subjectrow[subject_code]</td>";
echo "<td class='td_c' align='center'>$subjectrow[description]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lab_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lec_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[unit]</td>";
echo "</tr>";
$total=$newtotal+$subjectrow[unit];
$tot=$total;
}
}
else if($lev=="$row[yearlevel]" && $year=="$row[schoolyear]" && $sems=="")
{
$subjectquery="select * from subject where subject_id='$code'";
$result1=mysql_query($subjectquery) or die(mysql_error());
while($subjectrow=mysql_fetch_array($result1))
{
$newtotal=$tot;
extract($subjectrow);
echo "<tr style='background: maroon'>";
echo "<td class='td_c' align='center'>$subjectrow[subject_code]</td>";
echo "<td class='td_c' align='center'>$subjectrow[description]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lab_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lec_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[unit]</td>";
echo "</tr>";
$total=$newtotal+$subjectrow[unit];
$tot=$total;
}
}
else if($sems=="$row[semester]" || $lev=="$row[yearlevel]" && $year=="")
{
$subjectquery="select * from subject where subject_id='$code'";
$result1=mysql_query($subjectquery) or die(mysql_error());
while($subjectrow=mysql_fetch_array($result1))
{
$newtotal=$tot;
extract($subjectrow);
echo "<tr style='background: maroon'>";
echo "<td class='td_c' align='center'>$subjectrow[subject_code]</td>";
echo "<td class='td_c' align='center'>$subjectrow[description]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lab_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lec_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[unit]</td>";
echo "</tr>";
$total=$newtotal+$subjectrow[unit];
$tot=$total;
}
}
else if($sems=="$row[semester]" && $year=="$row[schoolyear]" && $lev=="$row[yearlevel]")
{
$subjectquery="select * from subject where subject_id='$code'";
$result1=mysql_query($subjectquery) or die(mysql_error());
while($subjectrow=mysql_fetch_array($result1))
{
$newtotal=$tot;
extract($subjectrow);
echo "<tr style='background: maroon'>";
echo "<td class='td_c' align='center'>$subjectrow[subject_code]</td>";
echo "<td class='td_c' align='center'>$subjectrow[description]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lab_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[lec_unit]</td>";
echo "<td class='td_c' align='center'>$subjectrow[unit]</td>";
echo "</tr>";
$total=$newtotal+$subjectrow[unit];
$tot=$total;
}
}
echo "<tr style='background: maroon'>";
echo "<td colspan='5' bgcolor='yellow' align='right'><font color='maroon'>TOTAL NUMBER OF UNITS TAKEN: $tot</font></td>";
echo "</tr>";
}
}
else
{
echo "No Records Found!";
}
}
?>
</table>
</div>
</td>
</table>
<div class="in_menu" style="border: 0px solid maroon; margin-bottom: 20px;" align="center">
<?php
$id = $_GET['user'];
$query = "SELECT * from studentaccess where student_id='$id'";
$result = mysql_query($query);
while($row=mysql_fetch_array($result))
{
extract($row);
@$userid = $row[student_id];
echo "<a style='margin-left: 15px;' href='student_profile.php?user=$userid''>Home</a> |
<a href='#.php'>Grade Information and Inquiry System via SMS</a> |
<a href='#.php'>Online Billing System</a> ";
}
?>
</div>
</div>
</div>
<div style="font-size: 12px; width: 1000px; margin: auto; color: white; font-family: verdana; border: 0px; margin-top: 40px; margin-bottom: 40px;" align="center">
<p>Copyright @ 2012 WMSU-MVTS-ESU, Molave, Zamboanga del Sur<br />All rights reserved.</p>
</div>
</body>
</html>