Re: Entity 'reg' not defined

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 22, 2010 at 11:47 AM, TR Shaw <tshaw@xxxxxxxx> wrote:

> Anyone have an idea how to work around this? I tried:
>
> define ('reg', '®');
> define ('&reg;', '®');
>
> can't figure how to override the entity table.  Errors follw:
>
> Warning: simplexml_load_string():
> o.cc/46/e53d68e007fd45c2fccb502f2e7ccad5.php?user_id=47&amp;sub_id=61862469&reg;
> in checkifup.php on line 5119
>
> Warning: simplexml_load_string():
>                                      ^ in checkifup.php on line 5119
>
> Warning: simplexml_load_string(): Entity: line 220: parser error : Entity
> 'reg' not defined in checkifup.php on line 5119
>
> Warning: simplexml_load_string():
> /office/e53d68e007fd45c2fccb502f2e7ccad5.php?user_id=47&amp;sub_id=89877485&reg;
> in checkifup.php on line 5119
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
Does doing a str_replace and changing it to the corresponding entity number
(&#174;) before parsing with simple_xml work?

Here's a more robust function:
http://www.sourcerally.net/Scripts/39-Convert-HTML-Entities-to-XML-Entities

Adam

-- 
Nephtali:  PHP web framework that functions beautifully
http://nephtaliproject.com

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux