Go4Expert

Go4Expert (http://www.go4expert.com/)
-   JavaScript and AJAX (http://www.go4expert.com/forums/javascript/)
-   -   need your help about HTML. (http://www.go4expert.com/forums/help-html-t21838/)

jackdalson 19Apr2010 14:48

need your help about HTML.
 
Hi Friends,

i am a fresher for I.T field. i have some questions for HTML. if you know about it please help me.
1> is it possible to display current time and date in my document? if yes explain me how?
2> is it possible to get my visitor's email address?How?
3> What is the difference between TT, KBD, SAMP?

help me for question.

Thanks in advanced.

Regards,

satyedra pal 21Apr2010 13:19

Re: need your help about HTML.
 
Hi,
For displaying current date and time in html we will use javascript without javascript it is difficult and done by the following:
HTML Code:

<html>
<head>
<script >

function clock()
{

var d = new Date()
var hours = d.getHours()
var minutes = d.getMinutes()
var seconds = d.getSeconds()
var tm = "AM";
if (hours > 11)
tm = "PM";
if (hours > 12)
hours = hours - 12;
if (hours == 0)
hours = 12;
if (minutes <= 9)
minutes = "0" + minutes;
if (seconds <= 9)
seconds = "0" + seconds;
var dispTime = "the time is :" +hours + ":" + minutes + ":" + seconds + " " + tm;
var dte = "<Br>Date of today is :" +d.getDate()+ "/" +d.getMonth()+ "/" +d.getFullYear();
setTimeout("clock()",500)
document.write(dispTime);
document.write(dte);
}
</script>

</head>
<body onload=clock()>
</body>
</html>

Problem with visitor E-mail address:
When any visitor is visiting on our profile or anywhere then we can find the record of all visitor for example name of the visitor or other view
information but we will find difficulty to find the Email address of that visitor, it is hide and can not be access by other.

Difference between TT,SAMP and KBD:-
TT=> This is a tag that use to display "teletype text or font" .
SAMP=> This is also a tag .It is used for showing program output in a monoscope font style.
KBD=> This tag is used for entering the text in a bold or special monoscope style.

ManzZup 7Aug2010 09:55

Re: need your help about HTML.
 
2) Problem with visitor e-mail:

You can use a guestbook or a commenting section, or at least a subscribe widget to get the email
BUT the email is given voluntarily by the user, not just collecting like the ip


All times are GMT +5.5. The time now is 20:07.