xml representation of current nodes:: >>> xml = PyQuery( ... ' <![[CDATA[ ]> ', parser='html_fragments') >>> print(str(xml)) <![[CDATA[ ]>
(self)
| 345 | return self |
| 346 | |
| 347 | def __str__(self): |
| 348 | """xml representation of current nodes:: |
| 349 | |
| 350 | >>> xml = PyQuery( |
| 351 | ... '<script><![[CDATA[ ]></script>', parser='html_fragments') |
| 352 | >>> print(str(xml)) |
| 353 | <script><![[CDATA[ ]></script> |
| 354 | |
| 355 | """ |
| 356 | return ''.join([etree.tostring(e, encoding=str) for e in self]) |
| 357 | |
| 358 | def __unicode__(self): |
| 359 | """xml representation of current nodes""" |