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

js/css在ajax UpdatePanel 中没有效果的解决方法

js没效果:如果在以UpdatePanel的方式的局部回传中,普通的Javascript代码在这种局部回传中就不会在触发了,就必须使用scriptmanager.RegisterClientScript方法(在<form>后面注册<script>)和scriptmanager.RegisterStartupScript方法(在</form之前注册<script>)
在你的用户控件的后端的某个合适位置,采用合适的注册方法,比如说load事件可以写以下代码:
//你的javascript代码
string script="var a='helloworld';alert(a);";
this.page.scriptmanager.RegisterStartupScript(this.page,typeof(string),"scriptforusercontrol",script,true);
css没效果:
string   s   =   @"<LINK   href="Css/Styles5.css"   type="text/css"   rel="stylesheet">";  
ClientScript.RegisterStartupScript(this.GetType(), "", s);
这样就可以了。


相关文档:

CSS Containing Floats

原文网址:http://www.complexspiral.com/publications
Containing Floats
As powerful and useful as they are, floats can make for tricky layout tools. Chances are that you may have seen something like the situation shown in Figure 1, which is accomplished with just two div elements, each with a floate ......

Ajax对象XMLHttpRequest的常用属性,方法和事件

XMLHttpRequest对象是Ajax的核心,它有许多属性,方法和事件以便于脚本的处理和控制HTTP的请求与响应
下面是关于XMLHttpRequest对象的一些属性和方法介绍
1.readyState属性
  当XMLHttpRequest对象被创建后,readyState属性标识了当前对象所处的状态,具体的值代表意义如下:
  0   未初始化状态, ......

Ajax应用的五个步骤

//Ajax应用的五个步骤
//1.创建XMLHttpRequest对象
var xmlHttp=createXMLHttpRequest();
function createXMLHttpRequest()

 var xmlHttp;
 if(Window.XMLHttpRequest)
 { 
  //IE6以上版本和其他浏览器内置XMLHttpRequest对象
  xmlHttp=new XMLHttpRequest(); ......

div+css(二)

前言:CSS布局与传统表格(table)布局最大的区别在于:原来的定位都是采用表格,通过表格的间距或者用无色透明的GIF图片来控制文布局版块的间距;而现在则采用层(div)来定位,通过层的margin,padding,border等属性来控制版块的间距。
 
(一)  CSS2盒模型
盒模型主要定义四个区域:内容(content)、边框距(paddin ......

jQuery Ajax 实例演示

<
script language=
"javascript"
>
 
$(
document)
.ready
(
function
(
)
{
$(
'#send_ajax'
)
.click
(
function
(
)
{
var
params=
$(
'input'
)
.serialize
(
)
;
//序列化表单的值
$.ajax
(
{
url:
'ajax_json.php'
,
//后台处 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号