要将 JavaScript 中的字符串转换为小写字母,请使用 toLocaleLowerCase() 方法。
您可以尝试运行以下代码来了解如何在 JavaScript 中使用 toLocaleLowerCase() 方法 -
实时演示
<!DOCTYPE html> <html> <body> <script> var a = "WELCOME!"; document.write(a.toLocaleLowerCase()); </script> </body> </html>
以上就是如何在JavaScript中将字符串转换为小写字母?的详细内容,更多请关注php中文网其它相关文章!
已抢65593个
抢已抢30374个
抢已抢16727个
抢已抢8457个
抢已抢10995个
抢已抢22613个
抢