我的问题如下。总的来说,我正在使用三个不同的页面,分别称为admin_home_page.php,student_panel.php和nav.js.对于第一页,代码如下:
<div style="text-align:center" class= "table_space" >
<table align="center" border = "0" >
<tr>
<td>
<form class="click" action="admin/students/student_panel.php" >
<input class="buton1" type = "button" value= "Studentet" />
</form>
</td>
<td>
<form class="click" action="admin/books/books_panel.php">
<input class = "buton1" type = "button" value= "Librat" />
</form>
</td>
<td>
<form class="click" action="admin/staf/staf_panel.php">
<input class = "buton1" type = "button" value= "Stafi" />
</form>
</td>
<td>
<form class="click" action="admin/other/more_panel.php">
<input class = "buton1" type = "button" value= "Te tjera" />
</form>
</td>
</tr>
</table>
</div>
<div id = "computing_area_id" class = "computing_area" > </div>
<div id="action_area" class="actions">
</div>
<script src="http://cdn.jquerytools.org/1.2.7/full/jquery.tools.min.js"></script>
<script type="text/javascript" src="admin/js/nav.js"></script>
<script type="text/javascript" src="profile/js/nav.js"></script>
<script type="text/javascript" src="admin/students/js/nav.js"></script>
对于第二页,student_panel.php,这是代码:
<body >
<p><a id="add" href="admin/students/student_computing.php" class="student_button" onclick="Print();">Shto Student</a></p>
<p><a id="delete" href="admin/students/student_computing.php" class="student_button" onclick="();">Fshi Student</a></p>
<script type="text/javascript" src="admin/students/js/nav.js"></script>
</body>
对于第三个,nav.js,这是代码:
$('.student_button').click(function(){
var href=$(this).attr('href');
$('#computing_area').hide().load(href).fadeIn('normal');
return false;
});
当我点击Studentet按钮时,我只会加载admin_home_page.php页面的一部分,即action_area,然后在页面的这一部分显示两个链接Shto Student和Fshi Student。当我点击Shto Student链接时,我还想加载一个名为computing_area的admin_home_page.php页面的一部分。现在在这部分中,computein_area应该被显示出来,但事实并非如此。
我们非常感谢您的回答,因为我们必须在接下来的两天内完成学校项目。