Reply to Re: [PHP] Extending Element class in a dom tree?

Your name:

Reply:


Posted by Erik Franzιn on 05/01/05 08:41

Christian Stocker wrote:

>>Does not work, will never work, just forget about it ;)
>
>
> Ok, that was not the really right answer ;) Of course it does work.
> You can even do stuff on that element, if you use the variable, resp.
> reference ($oMyElement) for doing this.
>
> What doesn't work (and I referred to that) is getting this object
> back from the DomDocument, so for example:
> $oDom->documentElement will give you the DomElement back and not your
> new MyElement.
>
> Hope it's a little bit clearer now
> chregu
>
>>chregu
>>

You mean that dom methods for retrieving Elements will only return
objects with the object methods defined in the DomElement class?

Is there any way to extend Elements in the tree with own methods? Or is
the dom structurue only used to handle defined methods?

The method DomDocument::CreateElement() only returns instances of
DomElement so maybee the Dom structure is not meant to be extended
regarding elements?

/Erik

[Back to original message]


УдалСнная Ρ€Π°Π±ΠΎΡ‚Π° для программистов  •  Как Π·Π°Ρ€Π°Π±ΠΎΡ‚Π°Ρ‚ΡŒ Π½Π° Google AdSense  •  England, UK  •  ΡΡ‚Π°Ρ‚ΡŒΠΈ Π½Π° английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Π‘Π°ΠΉΡ‚ ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ Π² Π‘Ρ‚ΡƒΠ΄ΠΈΠΈ Π’Π°Π»Π΅Π½Ρ‚ΠΈΠ½Π° ΠŸΠ΅Ρ‚Ρ€ΡƒΡ‡Π΅ΠΊΠ°
ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ΠΈΠ΅ ΠΈ ΠΏΠΎΠ΄Π΄Π΅Ρ€ΠΆΠΊΠ° Π²Π΅Π±-сайтов, Ρ€Π°Π·Ρ€Π°Π±ΠΎΡ‚ΠΊΠ° ΠΏΡ€ΠΎΠ³Ρ€Π°ΠΌΠΌΠ½ΠΎΠ³ΠΎ обСспСчСния, поисковая оптимизация