Advertisements
Today we are share how to show current date and Time in your blogger template in any where.
1) Log in to your blogger account and Go to your blogger dashbord.
2) Click on now --> Template--> Edit HTML
3) Now search </b:skin>
4) Copy the code from below and paste the code above/before </b:skin>
Code
#SpiceTarikh {
background: none repeat scroll 0 0 #000000;
display: inline-block;
color:#FFFFFF;
float: right;
font:100% 'Oswald',Sans-Serif;
padding: 5px 10px;
}
#SpiceTarikh a {
font-weight: bolder;
padding: 13px 16px 16px;
}
....Customization
Find .. <nav id='topnav'> .
Copy the code from below and paste the code above/before <nav id='topnav'>
<script type='text/javascript'>
//<![CDATA[
function makeArray() {
for (i = 0; i<makeArray.arguments.length; i++)
this[i + 1] = makeArray.arguments[i];
}
var months = new makeArray('January','February','March','April','May',
'June','July','August','September','October','November','December');
var date = new Date();
var day = date.getDate();
var month = date.getMonth() + 1;
var yy = date.getYear();
var year = (yy < 1000) ? yy + 1900 : yy;
document.write(months[month]+ " " +day + ", " + year);
//]]></script>
</div>
Finannly Save It
1) Log in to your blogger account and Go to your blogger dashbord.
2) Click on now --> Template--> Edit HTML
3) Now search </b:skin>
4) Copy the code from below and paste the code above/before </b:skin>
Code
#SpiceTarikh {
background: none repeat scroll 0 0 #000000;
display: inline-block;
color:#FFFFFF;
float: right;
font:100% 'Oswald',Sans-Serif;
padding: 5px 10px;
}
#SpiceTarikh a {
font-weight: bolder;
padding: 13px 16px 16px;
}
....Customization
Find .. <nav id='topnav'> .
Copy the code from below and paste the code above/before <nav id='topnav'>
<script type='text/javascript'>
//<![CDATA[
function makeArray() {
for (i = 0; i<makeArray.arguments.length; i++)
this[i + 1] = makeArray.arguments[i];
}
var months = new makeArray('January','February','March','April','May',
'June','July','August','September','October','November','December');
var date = new Date();
var day = date.getDate();
var month = date.getMonth() + 1;
var yy = date.getYear();
var year = (yy < 1000) ? yy + 1900 : yy;
document.write(months[month]+ " " +day + ", " + year);
//]]></script>
</div>
Finannly Save It
Advertisements
1 Comments
How To Display Current Date And Time Using Javascript
ReplyDeleteThe Date object is an inbuilt datatype of JavaScript language. It is used to work with dates and times. The Date object is created by using new keyword, i.e. new Date(). we can fetch current date and time respect to country using javascript..
For More Info:- How To Display Current Date And Time Using Javascript