Wm Codes
Showing posts with label
JavaScript
.
Show all posts
Showing posts with label
JavaScript
.
Show all posts
Sunday, October 20, 2013
Age Counter Java script
The below script
counts how long you've lived, in
days+hours+minutes.
Directions: Step 1:
Copy this into
the <head> tags:
COPY CODE:
<script LANGUAGE="JAVASCRIPT"><br /> <!-- hide this script tag's contents from old browsers<br /> function lifetimer(){ <br /> <br /> today = new Date() <br /> <br /> BirthDay = new Date(document.live.age.value) <br /> <br /> timeold = (today.getTime() - BirthDay.getTime()); <br /> <br /> sectimeold = timeold / 1000; <br /> <br /> secondsold = Math.floor(sectimeold); <br /> <br /> msPerDay = 24 * 60 * 60 * 1000 ; <br /> <br /> timeold = (today.getTime() - BirthDay.getTime()); <br /> <br /> e_daysold = timeold / msPerDay; <br /> <br /> daysold = Math.floor(e_daysold); <br /> <br /> e_hrsold = (e_daysold - daysold)*24; <br /> <br /> hrsold = Math.floor(e_hrsold); <br /> <br /> minsold = Math.floor((e_hrsold - hrsold)*60); <br /> <br /> document.live.time1.value = daysold <br /> <br /> document.live.time2.value = hrsold <br /> <br /> document.live.time3.value = minsold <br /> <br /> window.status = "Well at the moment you are " + secondsold + "............ seconds old."; <br /> <br /> timerID = setTimeout("lifetimer()",1000) <br /> <br /> } <br /> // -- done hiding from old browsers --><br /> <br /> </script>
Read more »
Friday, October 18, 2013
HTML/xHTML, JS code Tester
<script type="text/javascript">
function preview()
{
var odiv=document.getElementById('outputdiv');
var idiv=document.getElementById('inputcode');
odiv.innerHTML=idiv.value;
}
</script>
Read more »
Thursday, June 13, 2013
Your last visit on site script
Your last visit on site script js script:
demo : http://adf.ly/Q5aax
visit this site http://adf.ly/Q5aax and copy this code:
<
script type
=
"text/javascript"
>
function
getCookie
(
c_name
)
{
if
(
document.
cookie
.
length
>
0
)
{
c_start
=
document.
cookie
.
indexOf
(
c_name
+
"="
)
;
if
(
c_start
!=-
1
)
{
c_start
=
c_start
+
c_name.
length
+
1
;
c_end
=
document.
cookie
.
indexOf
(
";"
,
c_start
)
;
if
(
c_end
==-
1
)
c_end
=
document.
cookie
.
length
;
return
unescape
(
document.
cookie
.
substring
(
c_start
,
c_end
)
)
;
}
Read more »
Home
Subscribe to:
Posts (Atom)