贵有恒.
var str="我爱中国";if(str.indexOf("中国")>=0){ alert("含有此字符串");}else{ alert("没有此字符串");}
posted on 2015-12-24 16:55 叫我小洋 阅读(140) 评论(0) 编辑 收藏 举报