I think there is a bug in PHP Tools for VS code.
The following code works in PHP, no error thrown, but PHP tools marks it as an error:
<?php // is used to add the addCData to the default
// VS code error message can be ignored
class SimpleXMLElementSC extends SimpleXMLElement {
public function addCData($cdata_text){
$node= dom_import_simplexml($this);
$no = $node->ownerDocument;
$node->appendChild($no->createCDATASection($cdata_text));
}
}
It shows this message here:
Class SimpleXMLElementSC does not implement abstract methods:
function getChildren()
function hasChildren()
function current()
function key()
function next()
function rewind()
function valid()PHP(PHP2414)
class SimpleXMLElementSC extends SimpleXMLElement
Can you fix it? Should be a bug