|
|
 |
Re: FN-FORUM: Javascript problem (another one!)
date posted 8th August 2003 20:37
Hi Luke, I was trying out the script you sent and I'm not sure if I'm using
it properly...
I've put the function in and I have the following mouseovers and outs:
Introduction
How does this on-line course work?
Registration Form
Study Plan
Link 4
Each time I hover I get:
document.all[...].style is null or not an object
I'm afraid I can't see where I'm making a mistake....
Also, I wanted to show the divs onClick - I was getting the same error and
being diverted to my folder and it was bugging me so I changed it for ease
of testing! But it also occured to me that I would need to swapout each div
something like this:
Link 4
Would this make sense? I couldn't tell if it would have worked because I
was getting the same error as above....
Can you shed any light on it?
Very much appreciated if you can!
Nita
;o)
----- Original Message -----
From: "Nita" [EMAIL REMOVED]
To: [EMAIL REMOVED]
Sent: Friday, August 08, 2003 4:35 PM
Subject: Re: FN-FORUM: Javascript problem (another one!)
>
> Thanks again...
>
> too hot for all this thinking!
>
> ;o)
> ----- Original Message -----
> From: "Luke Perman" [EMAIL REMOVED]
> To: [EMAIL REMOVED]
> Sent: Friday, August 08, 2003 4:31 PM
> Subject: Re: FN-FORUM: Javascript problem (another one!)
>
>
>
> hi nita
>
> if you are gonna toggle the property of the layer, your path to it in
> javascript will be:
>
> document.all[theLayer].style.visibility
>
> not
>
> document.all.[theLayer]....
>
> note - the extra '.' you have before the [
>
> HTH
> luke
>
> On Friday, August 8, 2003, at 03:19 PM, Nita wrote:
>
> >
> > Thanks Alan, I'm considering using the visibility option - but after
> > trying
> > this out it seems fiddly, I keep getting an error (testing on IE6 ....
> > document.all.[...] is null or not an object).
> >
> > I must double-check the version of netscape that's to be used, if it's
> > 6
> > I'll continue to play with the innerhtml as that was probably closer to
> > working!
> >
> > Nita
> > ;o)
> > ----- Original Message -----
> > From: "Alan Sheppard" [EMAIL REMOVED]
> > To: [EMAIL REMOVED]
> > Sent: Friday, August 08, 2003 2:20 PM
> > Subject: RE: FN-FORUM: Javascript problem (another one!)
> >
> >
> >>
> >>
> >> I seem to recall that the default object for innerHTML in NS6+/IE5+ is
> >> document.all and that NS uses the Class or Name tag and IE uses the
> >> Id tag
> >> to identify the DIV.
> >>
> >> For stuff that I know is only for IE5/NS6 I use
> >> document.getElementById([idname]).innerHTML = "[myhtml]" which seems
> >> to
> >> work.
> >>
> >> If you need to go further back (IE4/NS4 etc) then you'll need to use
> >> layer/Div/Visible methods as luke has suggested.
> >>
> >> Alan S
> >>
> >>
> >> On 08 August 2003 12:18, Nita [EMAIL REMOVED] wrote:
> >>>
> >>> Hi all, I was wondering if anyone can help with this, I'm sure it's
> >>> very
> >>> simple but it's causing me some pain - for the past hour and a half
> >>> !!
> >>>
> >>> I'm trying to change the html content of a particluar CSS div when a
> > user
> >>> clicks on a link in another part of the document. A working (in IE6)
> >>> prototype example is available at
> >>> http://www.staff.city.ac.uk/~ra735/frenchvita.html (the page design
> >>> is
> >> also
> >>> half way through so please ignore the odd bgimage). This is not
> > designed
> >> to
> >>> be cross-browser compatible, but that's what I'm working on just
> >>> now...
> >>>
> >>> .....And it's working fine in IE6 and although I believe that
> >> "innerHTML"
> >>> is supported in Netscape 6+ it's not working in NN7.1 - when I click
> >>> on
> >> the
> >>> links it just reloads the page. I think it's something to do with
> >>> how
> >> I'm
> >>> actually assigning the content - rather than how I'm finding the
> >> div/layer,
> >>> but I'm not sure what I should be doing....
> >>>
> >>> Any help/suggestions very much appreciated,
> >>> thanks in advance
> >>> Nita
> >>>
> >>
> >> ==========
> >> fido.net are pleased to sponsor these Freelancers messages. For all
> >> your web hosting needs check out http://www.fido.net/ with hosting
> >> packages starting from just £46.95 a year including VAT.
> >> Free 0871 Fax2Email numbers also available online!
> >> http://www.fido.net/ - the internet made simple! - 0800 1072 666
> >>
> >> To advertise here: http://www.freelancers.net/advertising.html
> >>
> >>
> > ==========
> > fido.net are pleased to sponsor these Freelancers messages. For all
> > your web hosting needs check out http://www.fido.net/ with hosting
> > packages starting from just £46.95 a year including VAT.
> > Free 0871 Fax2Email numbers also available online!
> > http://www.fido.net/ - the internet made simple! - 0800 1072 666
> >
> > To advertise here: http://www.freelancers.net/advertising.html
> >
> >
> ===fido.net are pleased to sponsor these Freelancers messages. For all
> your web hosting needs check out http://www.fido.net/ with hosting
> packages starting from just £46.95 a year including VAT.
> Free 0871 Fax2Email numbers also available online!
> http://www.fido.net/ - the internet made simple! - 0800 1072 666
>
> To advertise here: http://www.freelancers.net/advertising.html
>
> Unsub: http://www.freelancers.net/rm.php?g58087702119363077
>
> To Post a New Message: [EMAIL REMOVED]
> Forum Homepage: http://www.freelancers.net/forum.php
>
> http://www.freelancers.net - freelancers and freelance jobs
>
>
> ==========
> fido.net are pleased to sponsor these Freelancers messages. For all
> your web hosting needs check out http://www.fido.net/ with hosting
> packages starting from just £46.95 a year including VAT.
> Free 0871 Fax2Email numbers also available online!
> http://www.fido.net/ - the internet made simple! - 0800 1072 666
>
> To advertise here: http://www.freelancers.net/advertising.html
>
> |
 |
|