3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = "</ul>\n<p>\n Evaluation<!--[if gte mso 9]><xml>\n<o:OfficeDocumentSettings>\n<o:AllowPNG />\n<o:TargetScreenSize>1024x768</o:TargetScreenSize>\n</o:OfficeDocumentSettings>\n</xml><![endif]--><!--[if gte mso 9]><xml>\n<w:WordDocument>\n<w:View>Normal</w:View>\n<w:Zoom>0</w:Zoom>\n<w:HyphenationZone>21</w:HyphenationZone>\n<w:PunctuationKerning />\n<w:ValidateAgainstSchemas />\n<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>\n<w:IgnoreMixedContent>false</w:IgnoreMixedContent>\n<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>\n<w:Compatibility>\n<w:BreakWrappedTables />\n<w:SnapToGridInCell />\n<w:WrapTextWithPunct />\n<w:UseAsianBreakRules />\n<w:DontGrowAutofit />\n</w:Compatibility>\n</w:WordDocument>\n</xml><![endif]--><!--[if gte mso 9]><xml>\n<w:LatentStyles DefLockedState=\"false\" LatentStyleCount=\"156\">\n</w:LatentStyles>\n</xml><![endif]--><!--[if gte mso 10]>\n<style>\n/* Style Definitions */\ntable.MsoNormalTable\n{mso-style-name:\"Normale Tabelle\";\nmso-tstyle-rowband-size:0;\nmso-tstyle-colband-size:0;\nmso-style-noshow:yes;\nmso-style-parent:\"\";\nmso-padding-alt:0cm 5.4pt 0cm 5.4pt;\nmso-para-margin:0cm;\nmso-para-margin-bottom:.0001pt;\nmso-pagination:widow-orphan;\nfont-size:10.0pt;\nfont-family:\"Times New Roman\";\nmso-ansi-language:#0400;\nmso-fareast-language:#0400;\nmso-bidi-language:#0400;}\n</style>\n<![endif]--></p>\n<ul>\n <li>"; $dom = new DOMDocument; $dom->loadHtml($str); $xpath = new DOMXPath($dom); foreach ($xpath->query('//comment()') as $comment) { $comment->parentNode->removeChild($comment); } echo $dom->saveXML($str);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 15, Position 2 = 21
Branch analysis from position: 15
2 jumps found. (Code = 78) Position 1 = 16, Position 2 = 21
Branch analysis from position: 16
1 jumps found. (Code = 42) Position 1 = 15
Branch analysis from position: 15
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 21
filename:       /in/tFGZp
function name:  (null)
number of ops:  27
compiled vars:  !0 = $str, !1 = $dom, !2 = $xpath, !3 = $comment
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3C%2Ful%3E%0A%3Cp%3E%0A++++Evaluation%3C%21--%5Bif+gte+mso+9%5D%3E%3Cxml%3E%0A%3Co%3AOfficeDocumentSettings%3E%0A%3Co%3AAllowPNG+%2F%3E%0A%3Co%3ATargetScreenSize%3E1024x768%3C%2Fo%3ATargetScreenSize%3E%0A%3C%2Fo%3AOfficeDocumentSettings%3E%0A%3C%2Fxml%3E%3C%21%5Bendif%5D--%3E%3C%21--%5Bif+gte+mso+9%5D%3E%3Cxml%3E%0A%3Cw%3AWordDocument%3E%0A%3Cw%3AView%3ENormal%3C%2Fw%3AView%3E%0A%3Cw%3AZoom%3E0%3C%2Fw%3AZoom%3E%0A%3Cw%3AHyphenationZone%3E21%3C%2Fw%3AHyphenationZone%3E%0A%3Cw%3APunctuationKerning+%2F%3E%0A%3Cw%3AValidateAgainstSchemas+%2F%3E%0A%3Cw%3ASaveIfXMLInvalid%3Efalse%3C%2Fw%3ASaveIfXMLInvalid%3E%0A%3Cw%3AIgnoreMixedContent%3Efalse%3C%2Fw%3AIgnoreMixedContent%3E%0A%3Cw%3AAlwaysShowPlaceholderText%3Efalse%3C%2Fw%3AAlwaysShowPlaceholderText%3E%0A%3Cw%3ACompatibility%3E%0A%3Cw%3ABreakWrappedTables+%2F%3E%0A%3Cw%3ASnapToGridInCell+%2F%3E%0A%3Cw%3AWrapTextWithPunct+%2F%3E%0A%3Cw%3AUseAsianBreakRules+%2F%3E%0A%3Cw%3ADontGrowAutofit+%2F%3E%0A%3C%2Fw%3ACompatibility%3E%0A%3C%2Fw%3AWordDocument%3E%0A%3C%2Fxml%3E%3C%21%5Bendif%5D--%3E%3C%21--%5Bif+gte+mso+9%5D%3E%3Cxml%3E%0A%3Cw%3ALatentStyles+DefLockedState%3D%22false%22+LatentStyleCount%3D%22156%22%3E%0A%3C%2Fw%3ALatentStyles%3E%0A%3C%2Fxml%3E%3C%21%5Bendif%5D--%3E%3C%21--%5Bif+gte+mso+10%5D%3E%0A%3Cstyle%3E%0A%2F%2A+Style+Definitions+%2A%2F%0Atable.MsoNormalTable%0A%7Bmso-style-name%3A%22Normale+Tabelle%22%3B%0Amso-tstyle-rowband-size%3A0%3B%0Amso-tstyle-colband-size%3A0%3B%0Amso-style-noshow%3Ayes%3B%0Amso-style-parent%3A%22%22%3B%0Amso-padding-alt%3A0cm+5.4pt+0cm+5.4pt%3B%0Amso-para-margin%3A0cm%3B%0Amso-para-margin-bottom%3A.0001pt%3B%0Amso-pagination%3Awidow-orphan%3B%0Afont-size%3A10.0pt%3B%0Afont-family%3A%22Times+New+Roman%22%3B%0Amso-ansi-language%3A%230400%3B%0Amso-fareast-language%3A%230400%3B%0Amso-bidi-language%3A%230400%3B%7D%0A%3C%2Fstyle%3E%0A%3C%21%5Bendif%5D--%3E%3C%2Fp%3E%0A%3Cul%3E%0A++++%3Cli%3E'
    5     1        NEW                                              $5      'DOMDocument'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !1, $5
    6     4        INIT_METHOD_CALL                                         !1, 'loadHtml'
          5        SEND_VAR_EX                                              !0
          6        DO_FCALL                                      0          
    8     7        NEW                                              $9      'DOMXPath'
          8        SEND_VAR_EX                                              !1
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !2, $9
    9    11        INIT_METHOD_CALL                                         !2, 'query'
         12        SEND_VAL_EX                                              '%2F%2Fcomment%28%29'
         13        DO_FCALL                                      0  $12     
         14      > FE_RESET_R                                       $13     $12, ->21
         15    > > FE_FETCH_R                                               $13, !3, ->21
   10    16    >   FETCH_OBJ_R                                      ~14     !3, 'parentNode'
         17        INIT_METHOD_CALL                                         ~14, 'removeChild'
         18        SEND_VAR_EX                                              !3
         19        DO_FCALL                                      0          
    9    20      > JMP                                                      ->15
         21    >   FE_FREE                                                  $13
   12    22        INIT_METHOD_CALL                                         !1, 'saveXML'
         23        SEND_VAR_EX                                              !0
         24        DO_FCALL                                      0  $16     
         25        ECHO                                                     $16
         26      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.71 ms | 1399 KiB | 13 Q