For Hosts Locale how to convert a string to lowercase letters in JavaScript?



To convert a string to lowercase letters in JavaScript, use the toLocaleLowerCase() method.

Example

You can try to run the following code to learn how to work with toLocaleLowerCase() method in JavaScript −

Live Demo

<!DOCTYPE html>
<html>
   <body>
      <script>
         var a = "WELCOME!";
         document.write(a.toLocaleLowerCase());
      </script>
   </body>
</html>
Lakshmi Srinivas
Lakshmi Srinivas

Programmer / Analyst / Technician


Advertisements