How to get a timestamp in JavaScript

Below are the ways to get a timestamp in Javascript.

Date.now returns the UTC timestamp in milliseconds.

If you are using IE you can use the below code.

if (!Date.now) {
    Date.now = function now() {
        return new Date().getTime();
    };
}
To convert the timestamp in seconds use below code

Math.floor(Date.now() / 1000)

jQuery Tutorial for Beginners - Hello World Example

Below is a Jquery example of how to print "Hello World" to the Console.

<html>
<head>
<title>jQuery Example in Developersarena</title>
<script type="text/javascript" 
   src="http://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js">
</script>
<script type="text/javascript">
   $(document).ready(function(){
      document.write("Hello, World!");
   });
</script>   
</head>
<body>
<h1>Hello</h1>
</body>
</html>