Re: html_dump_mem()

From: Date: Tue, 26 Oct 2004 06:49:56 +0000
Subject: Re: html_dump_mem()
References: 1  Groups: php.xml.dev 
Request: Send a blank email to php-xml-dev+get-491@lists.php.net to get a copy of this message
Hi As I already told you on php-general. It's not possible what you want. PHP doesn't have a built in HTML renderer. You have to use a Browser for that and then print from them. chregu On 26.10.2004 8:47 Uhr, franco bevilacqua wrote:
Hello, I have a question regarding the html_dump_mem function. I build an xml tree with HTML tags. When I dump it, I expect that my brother interpret HTML tag procduced by the dump. But the dump produce only a text with my html tag. Does someone knows how to do HTML interpretation with using DOMXML dump The following example explains exactly what whant to do. (Inspired from html_dump_mem example ) I see nothing wrong with the output, what exactly did you expect? chregu <?php // Creates the document $doc = domxml_new_doc("1.0"); $root = $doc->create_element("html"); $root = $doc->append_child($root); $body = $doc->create_element("body"); $body = $root->append_child($head); $h1 = $doc->create_element("h1"); $h1 = $head->append_child($h1); $text = $doc->create_text_node("This is the header1"); $text = $title->append_child($text); echo $doc->html_dump_mem(); ?> The following dump is produced: <html><body><h1>This is the header1</h1></body></html> But I expect the following result: "This is the header1" : formated as HTML header1 Thanks for your help. Best regards Franco
-- christian stocker | Bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich phone +41 1 240 56 70 | mobile +41 76 561 88 60 | fax +41 1 240 56 71 http://www.bitflux.ch | chregu@bitflux.ch | gnupg-keyid 0x5CE1DECB

« previous php.xml.dev (#491) next »