Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
a few more notes for charset handling in Mojo::DOM
  • Loading branch information
kraih committed May 4, 2013
1 parent 1c342f9 commit e25838a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion lib/Mojo/DOM.pm
Expand Up @@ -582,7 +582,8 @@ has no parent.
$dom = $dom->parse('<foo bar="baz">test</foo>');
Parse HTML/XML document with L<Mojo::DOM::HTML>.
Parse HTML/XML document with L<Mojo::DOM::HTML>. Note that the HTML/XML will
be decoded if a C<charset> has been defined.
# Parse UTF-8 encoded XML
my $dom = Mojo::DOM->new->charset('UTF-8')->xml(1)->parse($xml);
Expand Down
6 changes: 4 additions & 2 deletions lib/Mojo/DOM/HTML.pm
Expand Up @@ -386,13 +386,15 @@ following new ones.
$html = $html->parse('<foo bar="baz">test</foo>');
Parse HTML/XML document.
Parse HTML/XML document. Note that the HTML/XML will be decoded if a
C<charset> has been defined.
=head2 render
my $xml = $html->render;
Render DOM to XML.
Render DOM to XML. Note that the XML will be encoded if a C<charset> has been
defined.
=head1 SEE ALSO
Expand Down

0 comments on commit e25838a

Please sign in to comment.