Hi there,
I have been searching for ages for code that will allow me to display php code stored in a databse on a page that will ignore the php syntax as ive typed it in a form. Alot like the forums here with the code tags. Can ne1 point me to a tutorial or give me some examples, will be greatly apprechiated thx
Pash
how to display php code read only on a .php page?
Moderator: General Moderators
Correct me if i am worng, if you just want to display PHP code, with no fancy coloring, you just don't include the <?php -- ?> php tags....
Or just regex and aget rid of them depending on what you are trying to do.
Most of my code uses concatenation anyways to parse my HTML templates, so whe i want to show the code i just concatenate a string containing the php code.
But that's the basics anyways.
Or just regex and aget rid of them depending on what you are trying to do.
Most of my code uses concatenation anyways to parse my HTML templates, so whe i want to show the code i just concatenate a string containing the php code.
But that's the basics anyways.
Check out highlight_file in the PHP manual.
-
kettle_drum
- DevNet Resident
- Posts: 1150
- Joined: Sun Jul 20, 2003 9:25 pm
- Location: West Yorkshire, England
