码迷,mamicode.com
首页 > Web开发 > 详细

php_note.txt

时间:2016-05-07 13:00:42      阅读:155      评论:0      收藏:0      [点我收藏+]

标签:

drop procedure if exists pro_reg;
delimiter //
create procedure pro_reg(in user varchar(20),in password varchar(20) ); 
begin 
insert into tb_adm (userword,password)values(user,password);
end
//
1) trim(‘   \"string\"‘, ‘\"sg‘);   // 最终输出:\"strin
2) trim(‘   \"string\"   ‘, ‘\"sg‘);   // 最终输出:\"string\"
3)trim(‘\"string\"‘, ‘\"sg‘);    // 最终输出:trin
<?php 
$str = " 使用函数trim去掉字符串两端空白字符 "; 
$str1 = trim($str); 
echo "处理前有".strlen($str)."个字符"; echo "<br/>"; 
//www.phpjc.cn echo "<br/>"; 
echo "使用trim函数处理后有".strlen($str1)."个字符"; 
?> 
<?php 
$str = "##使用函数trim去掉字符串两端特定字符####"; 
$str1 = trim($str,"#"); 
//为函数trim传入第二个参数,
trim将删除字符串$str两端的#字符 echo $str."<br>"; 
echo $str1; 
?> 
http://127.0.0.1/myworks/zzforum/post.php?type=%27post%27#revert

php_note.txt

标签:

原文地址:http://www.cnblogs.com/feng12345/p/5467947.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!