CakeFest 2025 Madrid: The Official CakePHP Conference

Dom\HTMLDocument::saveHtml

(PHP 8 >= 8.4.0)

Dom\HTMLDocument::saveHtmlSerializes the document as an HTML string

Description

public Dom\HTMLDocument::saveHtml(?Dom\Node $node = null): string

Serializes the document as an HTML string.

Parameters

node
The node to serialize. If not provided, the entire document is serialized.

Return Values

The serialized HTML document string in the current document encoding.

Errors/Exceptions

See Also

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top

Follow Lee on X/Twitter - Father, Husband, Serial builder creating AI, crypto, games & web tools. We are friends :) AI Will Come To Life!

Check out: eBank.nz (Art Generator) | Netwrck.com (AI Tools) | Text-Generator.io (AI API) | BitBank.nz (Crypto AI) | ReadingTime (Kids Reading) | RewordGame | BigMultiplayerChess | WebFiddle | How.nz | Helix AI Assistant