user2044390
user2044390

Reputation: 49

PHP with HTML output as Object

Is there a way to use html in php like in javascript, where I can do Element.append() or so. Like $html->body->header->append($menu)? Some class or something?

Upvotes: 0

Views: 72

Answers (1)

Martin Müller
Martin Müller

Reputation: 2535

Look at the DOM in PHP. Basically, DOMDocument provides functions similar to the Javascript DOM ones, although the DOM is a bit more difficult/complex to use in PHP.

Upvotes: 1

Related Questions