此代码有什么问题?
<?
$pages = array();
$pages["New_Student.php"] = "New_Student";
$pages["NewCourse.php"] = "NewCourse";
$pages["Payment.php"] = "Payment";
$pages["Newcontract.php"] = "New contract";
$pages["New_user.php"] = "New User";
$pages["logout.php"] = "Logout";
$activePage = "Admin_dashboard.php";
foreach($pages as $url=>$title):?>
<a <?php if($url === $activePage):?>class="current-demo" <?php endif; ?> href="<?php echo $url;?>">
<?php echo $title;?>
</a>
<?php endforeach; ?>
解析错误:语法错误,意外的'endforeach'(T_ENDFOREACH),预期文件结尾