php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #64819 MsgBox on error "Class MySimpleXMLelement could not implement interface Iterat"
Submitted: 2013-05-11 20:58 UTC Modified: 2013-05-18 17:27 UTC
From: hanskrentel at yahoo dot de Assigned: ab (profile)
Status: No Feedback Package: win32std (PECL)
PHP Version: 5.4.15 OS: Windows
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.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: hanskrentel at yahoo dot de
New email:
PHP Version: OS:

 

 [2013-05-11 20:58 UTC] hanskrentel at yahoo dot de
Description:
------------
Extending form SimpleXMLElement and implementing Iterator does not work. I can 
understand that (albeit it is a little pity). However this report is about getting 
a message box for a fatal error when running in CLI / Phpstorm.

I normally reported this kind of problems here in the bugtracker because the error 
shouldn't be given as a windows msgbox.

Test script:
---------------
class MySimpleXMLelement extends SimpleXMLElement implements Iterator
{

    public function current() {
        return current($this);
    }

    public function next() {
        next($this);
    }

    public function key() {
        return key($this);
    }

    public function valid() {
        return each($this);
    }

    public function rewind() {
        reset($this);
    }
}

Actual result:
--------------
Getting a standard Windows MsgBox with the following text:

"Class MySimpleXMLelement could not implement interface Iterator"

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-05-11 21:02 UTC] hanskrentel at yahoo dot de
I reported this against a wrong package, was actually looking for "standard 
windows" category or something. Sorry for the fuzz.
 [2013-05-12 13:42 UTC] ab@php.net
-Status: Open +Status: Feedback
 [2013-05-12 13:42 UTC] ab@php.net
Not reproducible for me with neither 5.4 nor 5.5. I just get on console

Fatal error: Class MySimpleXMLelement could not implement interface Iterator in 
Unknown on line 0

when running your test script.

Could you please provide more details about your php.ini and extensions loaded?
 [2013-05-18 17:27 UTC] ab@php.net
-Status: Feedback +Status: No Feedback -Assigned To: +Assigned To: ab
 [2013-05-18 17:27 UTC] ab@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 "Re-Opened". Thank you.


 [2013-10-03 12:27 UTC] hanskrentel at yahoo dot de
You should be able to reproduce this with the following two php.ini settings:

[PHP]
display_startup_errors = On
log_errors = On

Both need to be set to on as I have found out, otherwise the Msgbox is not shown.

You should be able to reproduce from command-line on windows with:

php -n -d display_startup_errors=1 -d log_errors=1 -r "class M extends SimpleXMLElement implements Iterator {}"
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 18:01:29 2024 UTC