By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,770 Members | 1,180 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,770 IT Pros & Developers. It's quick & easy.

onFocus/onBlur

P: n/a
For those who have been using Outlook Express, you must be pretty used to
the fact that whenever you focus on the preview section, the header for the
preview turns from grey to blue, while the text turns from black to white.

Here is my HTML script

###############################
<body marginheight="0" marginwidth="0" topmargin="0" leftmargin="0"
onFocus="document.bgColor='orange';document.body.f ont.fstag.fgColor='black'"
onBlur="document.bgColor='#D6D3CE';document.body.f ont.fstag.fgColor='white'"
bgcolor="#D6D3CE">
<table width="100%" height="100%" cellpadding="0" cellspacing="0"
border="0">
<tr>
<td width="100%" height="40"
style="border-width:1px;border-style:solid;border-color:threedhighlight
threeddarkshadow threeddarkshadow threedhighlight;" name="ts" id="ts">
<table width="100%" height="100%" cellpadding="0" cellspacing="3"
border="0">
<tr>
<td><font name="fstag"
style="font-family:tahoma;font-size:8pt;font-weight:bold">From:<br>Subject:<
/font></td>
<td>Actions</td>
</tr>
</table>
</td>
</tr>
<tr>
<td bgcolor="white" height="95%">&nbsp;</td>
</tr>
</table>
</body>
###############################

In this case, I want to change the text color for the word "From:" &
"Subject:" whenever this frame is being onFocus. Anyone figure out on this?
Thanks!
Jul 23 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
In article <42********@news.starhub.net.sg>, good@thinking enlightened us
with...
For those who have been using Outlook Express, you must be pretty used to
the fact that whenever you focus on the preview section, the header for the
preview turns from grey to blue, while the text turns from black to white.

Here is my HTML script


Anyone who allows script to run in their email client is just asking for
problems.
Most of us would never allow script to run in e-mail.
Those who do are either ignorant of the risks or very trusting of others. ;)

Then there are those of us who won't even allow images to show by default in
our client. :p

Since this sort of thing would only work in Outlook, I assume you know for
sure your users are only using Outlook? It's not like there aren't several
other popular clients out there, plus all the web-based clients like hotmail,
yahoo, and gmail.

--
--
~kaeli~
A man needs a mistress... just to break the monogamy.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #2

P: n/a
Hi Kaeli,

Nope. It's not an email system. I developed a system that is based in
Microsoft Outlook Express GUI. Instead of emails, it is transactions about
mails, fax and phone, just like what you see in FEDEX systems. We're in the
logistic & mail services business.

All I require is that of a javascript command that can allow onfocus and
onblur of a certain frame object.

Cheers,
Peter Tan


"kaeli" <ti******@NOSPAM.comcast.net> wrote in message
news:MP************************@nntp.lucent.com...
In article <42********@news.starhub.net.sg>, good@thinking enlightened us
with...
For those who have been using Outlook Express, you must be pretty used to the fact that whenever you focus on the preview section, the header for the preview turns from grey to blue, while the text turns from black to white.
Here is my HTML script

Anyone who allows script to run in their email client is just asking for
problems.
Most of us would never allow script to run in e-mail.
Those who do are either ignorant of the risks or very trusting of others.

;)
Then there are those of us who won't even allow images to show by default in our client. :p

Since this sort of thing would only work in Outlook, I assume you know for
sure your users are only using Outlook? It's not like there aren't several
other popular clients out there, plus all the web-based clients like hotmail, yahoo, and gmail.

--
--
~kaeli~
A man needs a mistress... just to break the monogamy.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #3

P: n/a
In article <42********@news.starhub.net.sg>, good@thinking enlightened us
with...
Hi Kaeli,

Nope. It's not an email system.
Ah, sorry, I misunderstood your comment about Outlook, then.
I developed a system that is based in
Microsoft Outlook Express GUI. Instead of emails, it is transactions about
mails, fax and phone, just like what you see in FEDEX systems. We're in the
logistic & mail services business.

All I require is that of a javascript command that can allow onfocus and
onblur of a certain frame object.


Is this a real browser window or a component object?
Assuming it's a real browser window, a frame is still just a window object.
You can do all the same things with it, including trap onFocus and onBlur.
If the html/script that you posted is what you actually are trying to use, it
doesn't work because you're addressing the properties all wrong. I looked at
that and thought it was some sort of Outlook script or something. :)
You don't apply style to a font tag. You apply style to an actual element in
the page and ditch the font tag.
And WTF is this?
style="border-width:1px;border-style:solid;border-color:threedhighlight
threeddarkshadow threeddarkshadow threedhighlight;"

Make your stuff use CSS classes properly and then check this out. I think
it's more what you're going for.
http://www.webreference.com/js/column66/8.html

--
--
~kaeli~
I can't sleep. The clowns might eat me.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.