AMP_Base_Embed_Handler::maybe_remove_script_sibling

AMP_Base_Embed_Handler::maybe_remove_script_sibling( DOMElement $node,  callable $match_callback )

Description #

Removes the node's nearest <script> sibling with a src attribute containing the base src URL provided.


Parameters #

$node

(Required) The DOMNode to whose sibling is the script to be removed.

$match_callback

(Required) Callback which is passed the script element to determine if it is a match.



Changelog #

Changelog
Version Description
2.1 Introduced.