当弹出提示窗口用的Response.Write()时,原来页面的样式就不管用了。使用如下:ClientScript.RegisterClientScriptBlock(GetType(), "_error", "");//写成一个方法,以便多处调用:public static voidAlert(P...
分类:
其他好文 时间:
2014-09-01 13:59:03
阅读次数:
177
声明
实习森的理解层次,希望有错大家一起纠正
本文主要信息来自网友共享的一个JSPAPI,不是特别全,只是对jsp内置对象进行了简单的介绍,这里我总结了一下
正文
Jsp主要内置了9个对象,分别为:Application、Exception、Out、PageContext、Page、Request、Response、Session以及Config,详细如下:
Applicat...
分类:
Web程序 时间:
2014-09-01 00:30:32
阅读次数:
178
I was trying to play around with HTML5 assuming that VS 2010 had shipped with HTML5 support but to my dismay it was not the case. Bummer! So I did a b...
分类:
Web程序 时间:
2014-08-31 14:29:21
阅读次数:
234
前段时间想直接在mvc用一种最笨的方式输出一段脚本,所以就想到了Response.Write,但是后来发现很有问题,因为用这种方式输出的东西是直接在页面中第一行出现,所以脚本函数根本就调用不到,所以才改用html.raw()今天观察了下传统的asp.net和mvc使用Response.Write输出...
分类:
Web程序 时间:
2014-08-30 22:59:40
阅读次数:
258
ASP.NET中的cookie:创建Cookie方法 (1) Response.Cookies["userName"].Value=“admin"; Response.Cookies[“userName”].Expires=DateTime.Now.AddDays(1); //如果不设置失效时间.....
分类:
其他好文 时间:
2014-08-30 17:41:49
阅读次数:
209
??在用cookie保存username的时候,发现cookie值不能存中文,报例如以下错:Control character in cookie value, consider BASE64 encoding your value发生错误在:response.addCookie(cookie);在...
分类:
其他好文 时间:
2014-08-30 11:10:59
阅读次数:
215
先编写hello.py,实现Web应用程序的WSGI处理函数:# hello.pydef application(environ, start_response): start_response('200 OK', [('Content-Type', 'text/html')]) ret...
分类:
编程语言 时间:
2014-08-29 23:54:48
阅读次数:
239
1.设置web.config文件。............或者:aspx文件中:2.传递中文之前,将要传递的中文参数进行编码,在接收时再进行解码。>> 进行传递string Name = "中文参数";Response.Redirect("B.aspx?Name="+Server.UrlEncode...
分类:
Web程序 时间:
2014-08-29 14:28:47
阅读次数:
226
protected void Page_Load(object sender, EventArgs e) { string str = "asdf进杂货"; Response.Write(GetChineseWords(str)); Respo...
分类:
其他好文 时间:
2014-08-29 14:22:57
阅读次数:
202
public HttpServletResponse download(String path, HttpServletResponse response) { try { // path是指欲下载的文件的路径。 File file = ne...
分类:
编程语言 时间:
2014-08-28 14:38:29
阅读次数:
228