Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] javascript DOM doubt


  • From: david at dorward.me.uk (David Dorward)
  • Subject: [Javascript] javascript DOM doubt
  • Date: Fri Aug 25 04:59:40 2006

On Fri, Aug 25, 2006 at 10:47:35AM +0100, suresh kumar wrote:

>       sorry for repeatively asking my doubt.

You should probably have a read of: http://perlmonks.org/?node_id=444996

>    i want to change the tree as
>             <div id='iedisplayarea'>     //parent node  
>                         |
>                 <img id='ashow'>              //child node of iedisplay area
>                         |
>                 <img id='ashow1'>            //child node of ashow

<img> elements cannot have children. The resulting (X)HTML:
  <div><img><img/></img></div>
would be invalid, so what you are asking for doesn't make sense.

I suspect you want the new image to be a sibbling of th existing one,
in which case it should be a child of iedisplayarea, not ashow.

-- 
David Dorward                                      http://dorward.me.uk