摘要: 字符串函数LENGTH() 字符长度LENTTHB() 字节长度;一个汉字内存中占用 2字节LTRIM、RTRIM、TRIM截串SUBSTR(表达式,位置,长度)Oracle 无左右取串函数,但可以使用变通方式完成。左取串: SUBSTR('abcdefg', 1, 3)右取串: SUBSTR('abcedfg', LENGTH('abcdefg')-3+1, 3)字符函数接受字符输入,并返回字符或数值。INITCAP(char)首字母大写LOWER(char)转换为小写UPPER(char)转换为大写LTRIM(char,set)左裁切RTRI 阅读全文
posted @ 2011-11-22 22:01 扯 阅读(3620) 评论(0) 推荐(1) 编辑
摘要: eval()函数,可将字符串转换为变量对象varthe_image=prompt("changeparrotorcheese","");varthe_image_name="window.document."+the_image;varthe_image_object=eval(the_image_name);the_image_object.src="ant.gif";<formaction=""method="post"name="myform" 阅读全文
posted @ 2011-11-22 21:49 扯 阅读(317) 评论(0) 推荐(0) 编辑
摘要: functionlastMonth(){vardt=document.getElementById("d1").innerText;varstrArr=dt.split('-');varyear=strArr[0];varmonth=strArr[1];varday=strArr[2];//一月的时候回到上一年的12月if(strArr[1]==1){year=year-1;month=12;}else{month=month-1;}if(month.toString().length==1){month='0'+month;}documen 阅读全文
posted @ 2011-11-22 21:45 扯 阅读(617) 评论(0) 推荐(0) 编辑