10.07.2017 Views

javascript_tutorial

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Javascript<br />

Example<br />

Try the following example.<br />

<br />

<br />

JavaScript setUTCSeconds Method<br />

<br />

<br />

<br />

var dt = new Date( "Aug 28, 2008 13:30:00" );<br />

dt.setUTCSeconds( 65 );<br />

document.write( dt );<br />

<br />

<br />

<br />

Output<br />

Thu Aug 28 2008 13:31:05 GMT+0530 (India Standard Time)<br />

setYear ()<br />

Javascript date setYear() method sets the year for a specified date according to<br />

universal time.<br />

Syntax<br />

Its syntax is as follows:<br />

Date.setYear(yearValue)<br />

Note: Parameters in the bracket are always optional.<br />

Parameter Detail<br />

yearValue: An integer value.<br />

Example<br />

Try the following example.<br />

<br />

260

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!