...

View Full Version : onFocus="This.Blur();" on buttons



Bluemonkey
04-11-2003, 01:15 PM
can i have this onFocus="This.Blur();" on buttons because i have got it at the monet but a thin black line still apears on my button. how can i get rid of it

thank you very much for the help

Mhtml
04-11-2003, 04:23 PM
Yes you can. Just remember that javascript is case sensitive.


onFocus="this.blur();"

Also this really belongs in either the html & css forum (http://www.codingforums.com/forumdisplay.php?s=&forumid=13) or the javascript forum (http://www.codingforums.com/forumdisplay.php?s=&forumid=2).

brothercake
04-11-2003, 04:43 PM
DON'T DO THIS. DON'T EVER EVER USE onfocus="this.blur()"

Because it makes your page utterly inaccessible for people who don't use a mouse. This came up quite recently - http://www.codingforums.com/showthread.php?s=&threadid=16140

Quiet Storm
04-11-2003, 06:03 PM
What the "King of the Sacred Mice" :D is trying to say (non-hostile like...) instead of calling it onFocus, instead, may we suggest you use onMouseUp...

onMouseUp="this.blur();"

:thumbsup:

You can, however, do whatever you like to your site... it is your site, anyway.

brothercake
04-11-2003, 06:15 PM
Originally posted by Quiet Storm
"King of the Sacred Mice" :D.
Well ... I come and go with this diplomacy lark :p

Vladdy
04-11-2003, 06:38 PM
Originally posted by Quiet Storm
it is your site, anyway.
True, but unless the author suffers from a bad case of narcissism (when all you do is look in the mirror thinking how cute you are), the web sites are build for the VISITORS

Quiet Storm
04-11-2003, 07:12 PM
Originally posted by Vladdy
True, but unless the author suffers from a bad case of narcissism (when all you do is look in the mirror thinking how cute you are), the web sites are build for the VISITORS

So.... people who design art - should create what the public wants to see?

brothercake
04-11-2003, 09:48 PM
Originally posted by Quiet Storm
So.... people who design art - should create what the public wants to see?
Not necessarily, but that's not the point -

Say you run a museum - the exhibits may be controversial, or not, but that's not an accessibility issue. The accessibility issues are, for example, whether you can get in with a wheelchair.

Apply that to a website and it's the same thing - the accessibility issues are whether people can navigate, comprehend, and use the site. Whether your visitors like it nor not, and whether that's important, is a different thing entirely.

bazz
04-12-2003, 01:22 AM
I absolutely agree brothercake. :thumbsup:

Unfortunately!!

Does the onMouseUp code work across all browsers? I have used the onfocus bit about 2500 times and think I'll change it for the next upload.

If the answer is yes, then what program can anyone recommend to make changing 2500 words on about 600 pages in one go??

Notepad just aint gonna do it. :(

brothercake
04-12-2003, 01:41 AM
Originally posted by bazz
what program can anyone recommend to make changing 2500 words on about 600 pages in one go??
You could try BK Replace EM (http://www.orbit.org/replace/)

mattover-matter
04-12-2003, 03:49 AM
onload = function() {
a_tags=document.getElementsByTagName('a')
for (i=0;i<a_tags.length;i++) {
a_tags[i].onfocus=blur_links
}
}

function blur_links() {
this.blur()
}

this gets rid of em all ^-^

brothercake
04-12-2003, 08:36 PM
Originally posted by mattover-matter
this gets rid of em all ^-^
I refer the honourable gentleman to the answer I gave some moments ago.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum