javascript web code example

Example 1: javascript

JavaScript is a text-based programming language used both on the client-side
and server-side that allows you to make web pages interactive.
Where HTML and CSS are languages that give structure and style to web pages,
JavaScript gives web pages interactive elements that engage a user.

Example 2: javascript tutorial

<html>
  <head>
  //Write your javascript code here
  <script>
    //Using this you can change content of p tag
  	document.getElementById("demo").innnerHTML = "Bye";
  </script>
  </head>
  <body>
   <div id="demo">
     <p> Hello </p>
	</div>
 </body>

Example 3: basic javascript

>'hello'.toUpperCase()
'HELLO'

Tags: