| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 542 人关注过本帖
标题:希望得道高人的指点。谢谢啦
只看楼主 加入收藏
亚洲飞鹰
Rank: 2
等 级:论坛游民
帖 子:35
专家分:17
注 册:2010-6-1
结帖率:57.14%
收藏
 问题点数:0 回复次数:2 
希望得道高人的指点。谢谢啦
<%@ page language="java" pageEncoding="utf-8"  import="java.util.*,net.fckeditor.*"%>
<%@ include file="/inc/taglib.jsp" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<%@ page contentType="text/html;charset=gb2312"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    <title>新闻管理页面</title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="cache-control" content="no-cache">
    <meta http-equiv="expires" content="0">   
    <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
    <meta http-equiv="description" content="This is my page">
    <script language="JavaScript" type="text/JavaScript">
        function checkBig()
        {
          if (document.form1.BigClassName.value=="")
          {
            alert("大类名称不能为空!");
            document.form1.BigClassName.focus();
            return false;
          }
        }
        function checkSmall()
        {
          if (document.form2.BigClassName.value=="")
          {
            alert("请先添加大类名称!");
            document.form1.BigClassName.focus();
            return false;
          }

          if (document.form2.SmallClassName.value=="")
          {
            alert("小类名称不能为空!");
            document.form2.SmallClassName.focus();
            return false;
          }
        }
        function ConfirmDelBig()
        {
           if(confirm("确定要删除此大类吗?删除此大类同时将删除所包含的小类和该类下的所有新闻,并且不能恢复!"))
             return true;
           else
             return false;
            
        }

        function ConfirmDelSmall()
        {
           if(confirm("确定要删除此小类吗?删除此小类同时将删除该类下的所有新闻,并且不能恢复!"))
             return true;
           else
             return false;
            
        }
        function extend(na1){
            alert(na1);
            var element = document.getElementsByName("na1");
            alert(element);
            element.display=(element.style.display =='none')?'':'none';
        }
    </script>
</head>


<body>
    <table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
          <tr>
            <td align="center" valign="top"><table width="90" border="0" align="center" cellpadding="0" cellspacing="0">
                <tr>
                  <td align="center" valign="top"><br> <a href="type?status=add1"><strong><font color="#FF0000"><u>添加新闻一级分类</u></font></strong></a><br><br>

                    <table width="500" border="0" cellpadding="3" cellspacing="1" bgcolor="#DEDFDE">
                      <tr bgcolor="#f7f7f7">
                        <td width="50%" height="30" align="center"><strong>栏 目 名 称</strong></td>
                        <td height="30" align="center"><strong>操 作 选 项</strong></td>
                      </tr>
                      <c:forEach items="${tlist}" var="n">
                          <tr bgcolor="#F2F8FF" class="tdbg">
                            <td width="233" height="22">
                            <img src="admin/images/tree_folder4.gif"  style="width:15px; height:15px"  onclick="return extend(${n.na1})">
                             ${n.na1}
                            </td>
                            <td align="right" style="padding-right:10"><a href="type?status=add2&type1=${n.tp1}"><font color="#FF0000">添加二级分类</font></a>
                              | <a href="type?status=modify&type1=${n.tp1}&name1=${n.na1}">修改</a>
                              | <a href="type?status=delete&type1=${n.tp1}" onClick="return ConfirmDelBig();">删除</a>
                            </td>
                          </tr>
                              <c:forEach items="${n.nalist}" var="m">
                                 <tr bgcolor="#F2F8FF" class="tdbg" name="${n.na1}" style="display:none">
                                    <td width="233" height="22">
                                    <img src="admin/images/tree_folder3.gif"  style="width:15px; height:15px">
                                    ${m.name2}
                                    </td>
                                     <td><a href="type?status=modify&name2=${m.name2}">修改</a>
                                      | <a href="type?status=delete&name2=${m.name2}" onClick="return ConfirmDelBig();">删除</a>
                                    </td>
                                 </tr>
                              </c:forEach>
                      </c:forEach>
                    </table>
                    <br> </td>
                </tr>
    </table>
</body>


<img src="admin/images/tree_folder4.gif"  style="width:15px; height:15px"  onclick="return extend(${n.na1})">这句话好像有问题,每次传过去的参数在js函数中都说参数不是一个对象。而且function extend()根本就不可以执行。不知道为什么,希望得到各位的指点。谢谢大家。
搜索更多相关主题的帖子: html head include PUBLIC import 
2011-07-24 05:58
亚洲飞鹰
Rank: 2
等 级:论坛游民
帖 子:35
专家分:17
注 册:2010-6-1
收藏
得分:0 
先给自己顶一下
2011-08-01 16:30
亚洲飞鹰
Rank: 2
等 级:论坛游民
帖 子:35
专家分:17
注 册:2010-6-1
收藏
得分:0 
问题已经解决了。谢谢那些光顾过的it人。。。。。。
2011-08-01 16:31
快速回复:希望得道高人的指点。谢谢啦
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.051755 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved