1--TEST-- 2tidyNode tests 3--SKIPIF-- 4<?php if (!extension_loaded('tidy')) die('skip'); ?> 5--FILE-- 6<?php 7 8$tidy=tidy_parse_string('<% %>', array('newline' => 'LF')); 9var_dump($tidy->Root()->child[0]->isAsp()); 10 11$tidy=tidy_parse_string('<# #>', array('newline' => 'LF')); 12var_dump($tidy->Root()->child[0]->isJste()); 13 14$tidy=tidy_parse_string('<html><body>text</body></html>'); 15var_dump($tidy->Root()->child[0]->child[1]->child[0]->isText()); 16 17$tidy=tidy_parse_string('<html><body><!-- comment --></body></html>', array('newline' => 'LF')); 18$n = $tidy->Root()->child[0]->child[1]->child[0]; 19var_dump($n->isComment()); 20var_dump((string)$n); 21var_dump((bool)$n); 22var_dump((double)$n); 23var_dump((int)$n); 24var_dump($tidy->Root()->child[0]->child[0]->hasSiblings()); 25 26?> 27--EXPECT-- 28bool(true) 29bool(true) 30bool(true) 31bool(true) 32string(16) "<!-- comment -->" 33bool(true) 34float(0) 35int(0) 36bool(true) 37