当前位置:首页 » 软件开发
开发技术指南» 文章正文
    引言: 下面到了关键部分乐。
 

 

 ·jsp语法(5)——scriptlet    »显示摘要«
    摘要: 表达式 scriptlet 包含一个有效的程序段. jsp 语法 <% code fragment %> 例子 <% string name = null; if (request.getparameter("name") == null) { %> <%@ include file="error.html" %> <% } else { fo......
    摘要: 问题:tomcat怎么设置访问密码?跟iis那种类似的 ? 回答: 例如你要控制对root目录下文件的访问: 首先更改$tomcat_home/root/web-inf/web.xml 1。在<web-app>和</web-app>之间加入 <security-constraint> <web-resour......


JSP中的TagLib应用(4)
上一页   ...其实很多情况下我们是使用已经提供的taglib.

别人/公司已经做好了tag与处理部分,打好了包 我们需要做的只是在我们的jsp中去应用. 【程序编程相关:http://www.myfaq.com

【推荐阅读:JSP生成jpeg图片用于投票

但是当我们自己做个taglib时, 就需要编写这部分tag handler了. 【扩展信息:JSP记事本程序

这里只针对上面文件里提到的insert tag,其他的为了避免重复,就不一一说明了

==================== inserttag.java==============================

/*

* $id: inserttag.java,v 1.13 2000/03/04 02:54:57 brydon exp $

* copyright 1999 sun microsystems, inc. all rights reserved.

* copyright 1999 sun microsystems, inc. tous droits réservés.

*/

package com.sun.estore.taglib;

import javax.servlet.jsp.jsptagexception;

import javax.servlet.jsp.tagext.tagsupport;

import com.sun.estore.util.debug;

/**

* this class is an easy interface to the jsp template or other

* text that needs to be inserted.

* @author greg murray

*/

public class inserttag extends tagsupport {

private boolean directinclude = false;

private string parameter = null;

private string templatename = null;

private template template = null;

private templateparameter templateparam = null;

/**

* default constructor

*/

public inserttag() {

super();

}

public void settemplate(string templatename){

this.templatename = templaten
...   下一页
 ·关于java的分页查询操作技术    »显示摘要«
    摘要: servlet版性能测试 主要考虑的servlet版运行方式有: 一:servlet在web容器中的运行机制 1. 单独一个无状态的servlet实例运行 即web容器里的多个线程调用一个servlet实例的运行方式 2. 多个servlet实例 在web容器中有多个servlet实例的对象池,并有多个web容器线程来分别调用执行 二:servlet 连接数据库的......
» 本期热门文章:

©2000-2007 All Rights Reserved. 最佳浏览:1024X768 MSIE