473,396 Members | 2,061 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

dhtml question: onfocusout event



below is the snippet of the code:

<a href="merc.htm" target="_new_merc" onfocusout=window.close
class="left_link">

I have an event inside the <a> tag

onfocusout=window.close

the w3 validator says there is no attribute "onfocusout"

there is no doctype declaration so the validator assumes html4
transitional

I am not able to achieve what i want: to close the window when the user
switches to different window

any ideas?

Nov 9 '05 #1
3 3740
Els
bb***@hotmail.com wrote:
below is the snippet of the code:

<a href="merc.htm" target="_new_merc" onfocusout=window.close
class="left_link">

I have an event inside the <a> tag

onfocusout=window.close

the w3 validator says there is no attribute "onfocusout"

there is no doctype declaration so the validator assumes html4
transitional

I am not able to achieve what i want: to close the window when the user
switches to different window

any ideas?


Just one:
I'd personally hate it if one would be able to close my browser window
just because I switched to my email client to check a new mail.

--
Els http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -
Nov 9 '05 #2
On 8 Nov 2005 22:53:04 -0800, bb***@hotmail.com wrote:
below is the snippet of the code:

<a href="merc.htm" target="_new_merc" onfocusout=window.close
class="left_link">

I have an event inside the <a> tag

onfocusout=window.close

the w3 validator says there is no attribute "onfocusout"
That's because there isn't. Checking the spec is a lot quicker than
asking here:
http://www.w3.org/TR/REC-html40/inte....html#h-18.2.3

there is no doctype declaration so the validator assumes html4
transitional

I am not able to achieve what i want: to close the window when the user
switches to different window

any ideas?


Yes. If I get a message popping up to say that an email has arrived, my
firewall tells me an application is asking permission to do something or
Windows wishes to apprise me of the fact that it has heroically
recovered from yet another serious error of its own making, then it's
highly unlikely that I want any of my browser windows to close. You
should ask yourself whether your readers will be so very different.

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Nov 9 '05 #3
On 8 Nov 2005 22:53:04 -0800, bb***@hotmail.com wrote:
onfocusout=window.close

the w3 validator says there is no attribute "onfocusout"


You're probably after "onblur", but this does sound a little trigger
happy
Nov 9 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: egg | last post by:
Dear Sir/Madam, I'm about to start a project, the idea is to have a web interface to let user specify the URL of a target HTML document, based on that URL, retrieved and parsed the HTML document...
2
by: David Zack | last post by:
Hello. I'm currently working on a tool for an intranet that allows a user to launch a Word document template from an HTML page on a corporate portal. I would now like to run a particular macro...
2
by: | last post by:
Hello All, Could some one send me information on DHTML tutorials where I can leand the differences between html and dhtml. Thanks, ...
4
by: bbass | last post by:
thanks to all that replyied to my previous post with the following code in question: <a href="merc.htm" target="_new_merc" onfocusout=window.close class="left_link"> i understand that the...
1
by: Bob T | last post by:
Hi All, I am a bit of a newbie but have a reasonable grasp of using ASP.net code. One thing I have wanted to find our for sometime is if there is a way to invoke DHTML methods from or after...
1
by: John | last post by:
Hi, I've decided to try to reduce duplicate code and simplify a seriously complicated page I have by using web user controls. My problem is; one of the controls contained within my new ascx,...
5
by: gimme_this_gimme_that | last post by:
I'd like to create my own version of google suggest GS. If you haven't seen GS check it out at : http://www.google.com/webhp?complete=1&hl=en I've reviewed several AJAX write-ups on the...
2
by: silpa | last post by:
Hi, I have placed two text boxes(server side) for Name and Age in asp.net 2.0. Their ids are txtPatientName and txtPatientAge. The validation to be done is both text boxes should not be...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.