Jump to content

Outputting HTML as text


StirCrazy

Recommended Posts

ok, well this should work. it just grabs the contents of the file and replaces all html characters. but to me it would all come out as jumbled and i dont think it would work for php, not sure. here:

[code=php:0]
$file = "http://www.phpfreaks.com/forums/index.php?topic=122711.0";

$contents = file_get_contents($file);
echo htmlentities($contents);
[/code]

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.