Data Function is Its Not working IN IE8
Posted on
16th Feb 2014 07:03 pm by
admin
This is my first time to use formums. I hope i can get solution for this problem.
view plaincopy to clipboardprint?
function Clientcalculateage() { var varClientDOB = new Date(document.getElementById("txtClientDOB").value); var dobYear = varClientDOB.getFullYear(); var dobMonth = varClientDOB.getMonth(); var dobday = varClientDOB.getDay(); if (!isNaN(dobYear) && !isNaN(dobMonth) && !isNaN(dobday)) { var age = displayage(dobYear, dobMonth, dobday, "years", 0, "rounddown"); if (Number(age) < 2) { age = displayage(dobYear, dobMonth, dobday, "months", 0, "rounddown"); document.getElementById("txtClientAge").value = age; } else { document.getElementById("txtClientAge").value = age; } } else { alert("please enter a numeric value"); document.getElementById("txtClientAge").value = "DD/MMM/YYYY" document.getElementById("txtClientAge").focus(); } } function Clientcalculateage()
{
var varClientDOB = new Date(document.getElementById("txtClientDOB").value);
var dobYear = varClientDOB.getFullYear();
var dobMonth = varClientDOB.getMonth();
var dobday = varClientDOB.getDay();
if (!isNaN(dobYear) && !isNaN(dobMonth) && !isNaN(dobday))
{
var age = displayage(dobYear, dobMonth, dobday, "years", 0, "rounddown");
if (Number(age) < 2)
{
age = displayage(dobYear, dobMonth, dobday, "months", 0, "rounddown");
document.getElementById("txtClientAge").value = age;
}
else
{
document.getElementById("txtClientAge").value = age;
}
}
else
{
alert("please enter a numeric value");
document.getElementById("txtClientAge").value = "DD/MMM/YYYY"
document.getElementById("txtClientAge").focus();
}
}view plaincopy to clipboardprint?
Did you know?Explore Trending and Topic pages for more stories like this.
This is my Javascript Function I call this function in Onchage Event.
When I change the date in CalenderExtender Control. Its working fine in FireFox Browser. but Its not working in IE8.
I don't know y? i try my solution but its not workin. finally i come to forums. Any one plz help me
No comments posted yet
Your Answer:
Login to answer
309
42
Other forums
Count Session and Trigger Events
I am New in PHP, seeking a method to count logged users by counting the sessions or any …, is
Inserting a check in checkbox from array value
Hello all,
I have a bit of code that works for a select option box, but does not work for my chec
Oracle Connectivity
Hi Every One,
Can we access SAP from oracle database.If it possible then please spec
Selecting an "empty" date formated field
How do you select an "empty" date field? I've tried the few ways I can think.
SQL> select
Save data in input fields when they press "BACK BUTTON"
Hi, this is html form: And let's say they get a error "Please enter ur title must be more then
HTML Form Server Side Validation
Hi, Im new here, im currently doing a website for a friend, and I have designed using snippets from
UDP server recvfrom() always returns -1? :(
Hello all,
I am getting a very strange error in my code :( I am writing a server application in C
Form a inline view based on the results of the previous query?
Hi Experts,
Can we form a inline view on the results of a previous query (another inline view)?
ASP.NET 2.0 - Enter Key - Default Submit Button
Hi,One of the most annoying things in developing web pages is handling the "Enter key" for form subm
How to read posted binary data from a mobile device and post it to a web server?
Here is the senario...
I have a mobile device (MD) that posts binary data to a Web Server (WS