HighDots Forums  

Using specific PHP functions with Includes

Macromedia Dreamweaver Macromedia Dreamweaver Discussions (macromedia.dreamweaver)


Discuss Using specific PHP functions with Includes in the Macromedia Dreamweaver forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
AngryCloud
 
Posts: n/a

Default Using specific PHP functions with Includes - 12-22-2007 , 02:15 AM






How can I use the 'htmlspecialchars' and 'nl2br' functions in PHP with an
include?

I want to include a text file on a page, but I want it displayed just how it
would be in notepad, with all of its line breaks and HTML tags shown as plain
text.


I have tried these so far, but they do not work:

readfile(nl2br(htmlspecialchars($filename)))

nl2br(htmlspecialchars(readfile($filename)))


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.