Reply to RE: [PHP] Re: XmlWriter::writeDTD bug...

Your name:

Reply:


Posted by "Jared Williams" on 12/07/05 14:23

> Jared Williams wrote:
> > Hi,
> >
> > $writer = new XmlWriter();
> > ...
> >
> > $writer->writeDtd('html', '-//W3C//DTD XHTML 1.0 Strict//EN',
> > 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd');
> >
> > produces no whitespace between the public & system ids like...
> >
> > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
> > Strict//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
> >
> > Has anyone got a workaround for this problem?
>
> libxml bug. Add $writer->setIndent(TRUE); before the writeDTD
> call (can revert it back right after if you dont want
> indenting). This will force whitespace insertion between the
> two - not pretty but its a workaround.
>

PS.
Yeah, thought it was libxml, hence didn't file a pecl bug report. But there does seem a problem with this method as can't
just have a publicId or a systemId, libxml function uses NULL as a parameter to specify which id you don't want to use. Which we've
lost with the PHP wrapper, as can only specify two strings.

And when pecl.php.net was reachable I'll report it.

Jared

[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

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация