how to fire an event when unicode UTF-8 used IN JAVASCRIPT
Hi all
I need to fire the event selectHandler() when unicode UTF-8 is used in JAVASCRIPT. If i use ASCII it is fired.
If i use unicode it is not fired.
Help please!
Show code examples of the associated HTML, the Javascript event handler you're talking about, and the connection between the two. Thanks.
This is the code i have written
function clearSelect(e) {
if(document.all) {
e = window.event;
}
var key;
if(document.all) {
key = e.keyCode;
} else {
key = e.which;
}
//alert(key);
if(key>=48 && key<=57 || key>=65 && key<=90 || key == 8 || key == 9 || key == 32 || key == 39) {
docl = document.form1.selpgm_sname.length;
for(j=0; j<docl; j++) {
document.form1.selpgm_sname.options[0] = null;
}
selectHandler(e);
} else if(key == 40) {
document.form1.selpgm_sname.focus();
} else {
if(document.layers) return false;
else if(document.all) e.returnValue = false;
}
}
function selectHandler(e) {
var str = document.form1.pgm_sname.value;
//alert("called");
var cnt = 0;
if(document.all) {
e = window.event;
}
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Bookmarks