Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Encoding HTML

by kryten (Scribe)
on Apr 14, 2000 at 13:01 UTC ( #7606=snippet: print w/ replies, xml ) Need Help??

Description: If you want to display some text that may contain html or html looking elements as part of a webpage, you can use the HTML::Entities module to easily encode and decode it for you.
use HTML::Entities;
my $encoded = encode_entities($html);
my $html = decode_entities( $encoded );
Comment on Encoding HTML
Download Code

Back to Snippets Section

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: snippet [id://7606]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (6)
As of 2015-07-07 11:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (88 votes), past polls