Req #61972 [Opn]: addchild treats text as a tag

2012-05-20 Thread crashyn at op dot pl
Edit report at https://bugs.php.net/bug.php?id=61972edit=1

 ID: 61972
 User updated by:crashyn at op dot pl
 Reported by:crashyn at op dot pl
 Summary:addchild treats text as a tag
 Status: Open
 Type:   Feature/Change Request
 Package:SimpleXML related
 Operating System:   Windows XP
 PHP Version:5.4.2
 Block user comment: N
 Private report: N

 New Comment:

?php
$xml_header = ?xml version='1.0' encoding='utf-8'?xml/;

$xml = new SimpleXMLElement($xml_header);
$xml-addChild(first_string,this is lt;mystringgt;);
$xml-addChild(second_string,this is lt; mystringgt;);
$xml-asXML(test.xml);
echo pre . $xml-first_string . br /;   // 'this is '
echo $xml-second_string . /pre;// 'this is  mystring'
?


Previous Comments:

[2012-05-16 20:55:00] riptide dot tempora at opinehub dot com

Can you provide a test script and its actual vs. expected output to show 
exactly what you mean?


[2012-05-07 21:09:58] crashyn at op dot pl

Description:

---
From manual page: http://www.php.net/simplexmlelement.addchild
---
addChild treats lt;my_stringgt; as a tag nd removes it completely







-- 
Edit this bug report at https://bugs.php.net/bug.php?id=61972edit=1


[PHP-BUG] Req #61972 [NEW]: addchild treats text as a tag

2012-05-07 Thread crashyn at op dot pl
From: 
Operating system: Windows XP
PHP version:  5.4.2
Package:  SimpleXML related
Bug Type: Feature/Change Request
Bug description:addchild treats text as a tag

Description:

---
From manual page: http://www.php.net/simplexmlelement.addchild
---
addChild treats lt;my_stringgt; as a tag nd removes it completely


-- 
Edit bug report at https://bugs.php.net/bug.php?id=61972edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=61972r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=61972r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=61972r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=61972r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=61972r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=61972r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=61972r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=61972r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=61972r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=61972r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=61972r=notwrong
Not enough info: 
https://bugs.php.net/fix.php?id=61972r=notenoughinfo
Submitted twice: 
https://bugs.php.net/fix.php?id=61972r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=61972r=globals
PHP 4 support discontinued:  
https://bugs.php.net/fix.php?id=61972r=php4
Daylight Savings:https://bugs.php.net/fix.php?id=61972r=dst
IIS Stability:   
https://bugs.php.net/fix.php?id=61972r=isapi
Install GNU Sed: 
https://bugs.php.net/fix.php?id=61972r=gnused
Floating point limitations:  
https://bugs.php.net/fix.php?id=61972r=float
No Zend Extensions:  
https://bugs.php.net/fix.php?id=61972r=nozend
MySQL Configuration Error:   
https://bugs.php.net/fix.php?id=61972r=mysqlcfg