On 16 December 2014 00:56:43 GMT, Tjerk Meesters <tjerk.meest...@gmail.com> wrote: >Hi, > >I was looking at the documentation for DOMDocument::loadHTML() [1] that >mentions the following: > >> This function may also be called statically to load and create a >DOMDocument object. The static invocation may be used when no >DOMDocument properties need to be set prior to loading. > >However, this can’t be done in strict mode [2]: > >> Strict Standards: Non-static method DOMDocument::loadHTML() should >not be called statically in … > >This behaviour seems to be intended when ZEND_ACC_ALLOW_STATIC is used >[3] and can be fixed by using ZEND_ACC_STATIC instead. > >My questions: > >1) Is that the right kind of fix? >2) Is ZEND_ACC_ALLOW_STATIC meant to be used only for BC? If not, why >are we raising strict errors?
Surely that's just the same as a userland method which happens not to use $this ("allow static") and one marked "static" so *must* be called statically? -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php