DOMNode::replaceChild

(PHP 5, PHP 7, PHP 8)

DOMNode::replaceChild Replaces a child

Beschreibung

public DOMNode::replaceChild(DOMNode $node, DOMNode $child): DOMNode|false

This function replaces the child child with the passed new node. If the node is already a child it will not be added a second time. If the replacement succeeds the old node is returned.

Parameter-Liste

node

The new node. It must be a member of the target document, i.e. created by one of the DOMDocument->createXXX() methods or imported in the document by DOMDocument::importNode.

child

The old node.

Rückgabewerte

The old node or false if an error occur.

Fehler/Exceptions

DOM_NO_MODIFICATION_ALLOWED_ERR

Raised if this node is readonly or if the previous parent of the node being inserted is readonly.

DOM_HIERARCHY_REQUEST_ERR

Raised if this node is of a type that does not allow children of the type of the node node, or if the node to put in is one of this node's ancestors or this node itself.

DOM_WRONG_DOCUMENT_ERR

Raised if node was created from a different document than the one that created this node.

DOM_NOT_FOUND

Raised if child is not a child of this node.

Siehe auch

Hier Kannst Du einen Kommentar verfassen


Bitte gib mindestens 10 Zeichen ein.
Wird geladen... Bitte warte.
* Pflichtangabe
Es sind noch keine Kommentare vorhanden.

Was genau bedeutet "Vibe Coding"? Ein tiefgehender Blick für Entwickler

In der Welt der Softwareentwicklung gibt es unzählige Wege, wie man an ein Projekt herangeht. Manche schwören auf strikte Planung, andere auf bewährte Algorithmen und wieder andere lassen sich von etwas ganz anderem leiten: ihrem Gefühl. ...

admin

Autor : admin
Kategorie: Software & Web-Development

PHP cURL-Tutorial: Verwendung von cURL zum Durchführen von HTTP-Anfragen

cURL ist eine leistungsstarke PHP-Erweiterung, die es Ihnen ermöglicht, mit verschiedenen Servern über verschiedene Protokolle wie HTTP, HTTPS, FTP und mehr zu kommunizieren. ...

TheMax

Autor : TheMax
Kategorie: PHP-Tutorials

Midjourney Tutorial - Anleitung für Anfänger

Über Midjourney, dem Tool zur Erstellung digitaler Bilder mithilfe von künstlicher Intelligenz, gibt es ein informatives Video mit dem Titel "Midjourney Tutorial auf Deutsch - Anleitung für Anfänger" ...

Mike94

Autor : Mike94
Kategorie: KI Tutorials

Tutorial veröffentlichen

Tutorial veröffentlichen

Teile Dein Wissen mit anderen Entwicklern weltweit

Du bist Profi in deinem Bereich und möchtest dein Wissen teilen, dann melde dich jetzt an und teile es mit unserer PHP-Community

mehr erfahren

Tutorial veröffentlichen

Provider stellt auf envelope-from um. Was muss ich bei meinem Code ändern?

Hallo Mein Web-Provider stellt bei seinen Mailkonten demnächst auf envelope-from um. Problem: Die Formulare auf meiner Webseite werden per Mail a ...

Geschrieben von PPV am 13.01.2026 18:05:52
Forum: PHP Developer Forum
übergabeproblem

Quote from StarkesWeb Code: $Market= $_POST["value"]; I think that line is wrong. It should be... Code: $Market = $_POST["Market"]; be called. ...

Geschrieben von JohnSnow am 13.01.2026 10:52:08
Forum: PHP Developer Forum
Wo man günstige lizenzierte Software bekommt

Ja, die Schlüssel sind sowohl für eine Neuinstallation als auch für die Aktivierung eines bereits installierten Systems geeignet. Wichtig ist, ...

Geschrieben von einermeiner am 13.01.2026 08:56:46
Forum: Ankündigungen
Wo man günstige lizenzierte Software bekommt

Ein interessantes Thema mit preiswerter Software. Sag mal, sind die Schlüssel für eine Neuinstallation geeignet oder nur für die Aktivierung ei ...

Geschrieben von daberty am 13.01.2026 08:45:51
Forum: Ankündigungen