php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #27517 SimpleXML dont get CDATA
Submitted: 2004-03-07 09:30 UTC Modified: 2004-06-21 19:36 UTC
From: cyppe at telia dot com Assigned:
Status: Not a bug Package: SimpleXML related
PHP Version: 5.0.0b4 (beta4) OS: linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: cyppe at telia dot com
New email:
PHP Version: OS:

 

 [2004-03-07 09:30 UTC] cyppe at telia dot com
Description:
------------
SimpleXML seems to work all good, except for getting a CDATA node, it returns nothing.

Really nothing more to say.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-03-07 09:41 UTC] derick@php.net
Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to "Open".

Thank you for your interest in PHP.

 [2004-03-13 05:01 UTC] sniper@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 [2004-03-31 19:49 UTC] jaba at inbox dot lv
SimpleXML does support CDATA, but it fails to show nodes consisting of CDATA when you call print_r() or var_dump().

It only says [tag_name] => simplexml_element Object

When you call $xmlobject->[tag_name] then you get what you expect, but with print_r() - no!
 [2004-03-31 19:51 UTC] jaba at inbox dot lv
Just wanted to add that this is PHP5 RC1 running on Windows XP
 [2004-06-21 19:24 UTC] schmich at uiuc dot edu
Same behavior confirmed with PHP5 RC3 on linux
 [2004-06-21 19:36 UTC] amt@php.net
SimpleXML overloads its objects, so they don't work correctly when you call print_r() and friends.

You should use the asXML() method if you're interested in viewing a text version of the object.
 
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Sun Oct 02 10:05:51 2022 UTC