下拉框树,HTML代码
很多时候,我们需要将下拉框里面的数据用树显示出来,这样会便于客户得到清晰的数据,而且比较直接,晾出以下HTML代码,可以直接复制到HTML代码里面运行!
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<script>
/*****************************************
auth: polarbear
data: 2009.04.17
******************************************/
//ucstar select
//id: select id
//name: select attribute name
//rootSelectname: select first option value
//sign: iterator options's prefix sign
//selectid: about the selected option id
function UcstarSelectObj(id,name,rootSelectname,sign,selectedid) {
this.id = id;
this.name = name;
this.rootSelectname = rootSelectname;
this.sign = sign;
this.selectedid = selectedid;
this.selectStr = "";
this.ucstaroptions = [];
this.ucstaroptionobjs = [];
}
//ucstar option
//id: option id
//name: option value
//pid: the node's parent id
//desc: the option's description
function UcstarOption(id,name,pid,desc) {
this.id = id;
this.name = name;
this.pid = pid;
this.desc = desc;
}
//get the options by parentid
UcstarSelectObj.prototype.getChildOptions = function(vPid) {
var childOptions = new Array();
//this.debug(this.ucstaroptions.length);
for(var i = 0; i < this.ucstaroptions.length; i++) {
if(this.ucstaroptions[i].pid == vPid) {
//this.debug(this.ucstaroptions[i].pid + "-" + this.ucstaroptions[i].id);
childOptions[childOptions.length] = this.ucstaroptions[i];
}
}
return childOptions;
}
//debug message
UcstarSelectObj.prototype.debug = function(message) {
相关文档:
using System.Text.RegularExpressions;
string ohtml = this.TextBox1.Text;
System.Text.RegularExpressions.MatchCollection m;
//提取字符串的图片
......
因为Wap2.0使用XHTML语言并兼容WML,以下是网上找的XHTML和HTML的区别
XHTML相比于HTML
1.所有的标记都必须要有一个相应的结束标记
以前在HTML中,你可以打开许多标签,例如和<li>而不一定写对应的
和</li>来关闭它们。但在XHTML中这是不合法的。XHTML要求有严谨的结构,所有标签必须 ......
最近项目中需要在页面中预览word文件,虽说word本身就可以在页面中打开,但是有两个弊端,1是可客户端必须安装word, 2是客户端的环境以及office版本有差异,会造成预览不稳定。在网上找了一下,发现poi可以把word装换成txt,但是格式都丢了,只有光秃秃的文本,又搜jacob, 网友们众说纷纭, 最后还是自己sourceforge上下载jaco ......
作者
崔康
发布于
2010年5月13日 下午10时14分
随着Web2.0技术的不断发展,Web前端的优化受到越来越多的关注,特别是JavaScript和CSS优化的讨论一直是热点,工具也
相对丰富,而对HTML优化则有所忽视,最近,来自百度泛用户体 ......
原文地址:http://www.php-oa.com/2009/09/24/perl-html-tree-builder-xpath.html
转过来 慢慢研究
强大的Perl中,有超级多强大的模块,让我们不在需要重复的发明轮子.下面这个就是一个强大的模块.HTML::TreeBuilder::XPath.它能象xml一样解析网站.怎么使用就不细讲了,如下,见实例,我是从alexa.com网站得到我的网站排名的一 ......