易截截图软件、单文件、免安装、纯绿色、仅160KB

HTML:MESSAGES,HTML:ERRORS,用法


=======<html:messages>============
Action 中 :
    ActionMessages message = new ActionMessages();
    message.add(" 消息句柄 ",new ActionMessage(" 资源文件中 Key 值 ",String 类型描述信息 ));
    this.addMessages(request,message);
    return ActionForward;
JSP 页面中 :
    <html:messages id=" 指定使用消息的标识 " property=" 消息句柄 " message="true|false">
       <bean:write name=" 以上所指 ID 标识 "/>
    </html:messages>
==========<html:errors>==============
Action 中 :
    ActionMessages message = new ActionMessages();
    message.add(" 消息句柄 ",new ActionMessage(" 资源文件中 Key 值 ",String 类型描述信息 ));
    this.saveErrors(request,message);
    return ActionForward;
JSP 页面中 :
    <html:errors property=" 消息句柄 "/>
如果Action中这样设定(false),页面的提示信息将不从资源文件里读取:
    ActionMessages message = new ActionMessages();
    message.add("消息句柄",new ActionMessage("String类型描述信息",false));
    this.saveErrors(request,message);
    return ActionForward;
JSP页面:
    <html:errors/>或<html:errors property="消息句柄"/>


相关文档:

HTML基础学习笔记

<html>
 <head>
  <title>            
   基础HTML学习
  </title>      <t/标题/t>
         & ......

Asp.net动态加载用户自定义控件,并转换成HTML代码

Ajax现在已经是相当流行的技术了,Ajax不仅是想服务器端发送消息,更重要的是无刷新的重载页面。
 如果页面单纯的使用js来创建,要写大量的代码,而且不直观。
在asp.net中,其实我们可以创建用户自定义控件,通过Ajax请求返回用户自定义控件HTML代码。
public static string RangerUsControl(string controlName) ......

让ASP.Net HTML页面代码 清爽起来

自从用了 ASP.Net MVC后就喜欢上了它 ,因为MVC对服务器控件的依赖大大减少,它生成的HTML页面就比WebForm清爽多了,加载速度有了明显的改善。
但对于页面中内嵌script,还是不能彻底的避免,如:
<script type="text/javascript" language="javascript">
//<!--
function DepositPa ......

HTML文本格式化

文本格式化标签
标签描述
<b>
定义粗体文本。
<big>
定义大号字。
<em>
定义着重文字。
<i>
定义斜体字。
<small>
定义小号字。
<strong>
定义加重语气。
<sub>
定义下标字。
<sup>
定义上标字。
<ins>
定义插入字。
<del>
定义删除字。 ......

在html中控制自动换行

在网上搜寻到2中解决方案:
1.其实只要在表格控制中添加一句
<td style="word-break:break-all">就搞定了。
其中可能对英文换行可能会分开一个单词问题:解决如下:
语法:
word-break : normal | break-all | keep-all
参数:
normal :  依照亚洲语言和非亚洲语言的文本规则,允许在字内换行
break-all ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号