没有合适的资源?快使用搜索试试~ 我知道了~
javaScript脚本技术和asp.net内置对象
需积分: 3 1 下载量 95 浏览量
2010-05-15
22:08:31
上传
评论
收藏 5KB TXT 举报
温馨提示
试读
6页
用于有心之人!真经名言乃可贵! javaScript脚本技术和asp.net内置对象 其实虽是基础,却也是重点!
资源推荐
资源详情
资源评论
-------设置首页----------------------------
<a href="#" onclick="this.style.behavior='url(#default#homepage)';this.sethomepage('http://localhost:2941/DelicacyWeb/WangYongjie/index.aspx')"><strong>设为首页</strong></a>
--------添加到收藏夹---------------------------
<a href="JavaScript:window.external.AddFavorite('http://localhost:2941/DelicacyWeb/WangYongjie/index.aspx','ASP.NET网站')" ><strong>添加到收藏夹</strong></a>
--------全屏显示当前页面---------------------------
<script language="javascript" type="text/javascript">
function opendialog(){
var width =screen.width;
var height = screen.height;
window.showModalDiaLog("index.aspx","","dialogWidth="+width+"px;dialogHeight="+height+"px;status=no;help=no;scrollbars=no");
}
</script>
<a href="#" onclick="opendialog()"><strong>全屏显示</strong></a>
---------动态获取浏览器性能--------------------------
//动态获取浏览器性能
HttpBrowserCapabilities mybc = Request.Browser;
lblType.Text = mybc.Type;
lblBrowser.Text = mybc.Browser;
lblVersion.Text = mybc.Version;
lblPlatform.Text = mybc.Platform;
lblFrames.Text = mybc.Frames.ToString();
lblTables.Text = mybc.Tables.ToString();
lblCookies.Text = mybc.Cookies.ToString();
lblJavaScript.Text = mybc.JavaScript.ToString();
lblVBscript.Text = mybc.VBScript.ToString();
---------动态获取ip地址及服务器名称信息--------------------------
//动态获取ip地址及服务器名称信息
lblUserId.Text = Request.UserHostAddress;
string hostName = Dns.GetHostName();
lblServerName.Text = hostName
;
IPAddress[] ips;
ips = Dns.GetHostAddresses(hostName);
foreach (IPAddress ip in ips)
{
lblServerId.Text = ip.ToString();
}
--------用户在线停留时间---------------------------
void Application_Start(object sender, EventArgs e)
{
// 在应用程序启动时运行的代码
Application["counter1"] = 0; //在应用程序启动时运行的代码
}
void Application_End(object sender, EventArgs e)
{
// 在应用程序关闭时运行的代码
lblVBscript.Text = mybc.VBScript.ToString();
---------动态获取ip地址及服务器名称信息--------------------------
//动态获取ip地址及服务器名称信息
lblUserId.Text = Request.UserHostAddress;
string hostName = Dns.GetHostName();
lblServerName.Text = hostName
;
IPAddress[] ips;
ips = Dns.GetHostAddresses(hostName);
foreach (IPAddress ip in ips)
{
lblServerId.Text = ip.ToString();
}
--------用户在线停留时间---------------------------
void Application_Start(object sender, EventArgs e)
{
// 在应用程序启动时运行的代码
Application["counter1"] = 0; //在应用程序启动时运行的代码
}
void Application_End(object sender, EventArgs e)
{
// 在应用程序关闭时运行的代码
剩余5页未读,继续阅读
资源评论
wsjr2010
- 粉丝: 63
- 资源: 4
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功