JavaScript字符串变大小写

var str = "hello world!";

var new_str = str.toUpperCase();

conlose.log(new_str);

HELLO WORLD!

new_str = str.toLowerCase();

hello world!

 

posted @ 2018-10-10 15:06  柳刚  阅读(828)  评论(0编辑  收藏  举报