|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
PHP Tutorial Making.
I want to make some basic tutorials and use color using the highlight_string(); command.... but when I do that I get my variables turned into blanks. How can I show the code properly?
Also why is it when I do it that way...I get this 1 right after that command when I run it in my browser. |
|
#2
|
|||
|
|||
|
RE: PHP Tutorial Making.
Hi,
If you want to achieve something like this: http://www.innovative-webdesign.co.uk/lukus/phpstuff/highlight3.php This is the code: ----- <?php echo "welcome, this is the script ur gonna use:"; echo "<hr>"; $string = ' <?php if($myName == 'Lukus') $myEmail = 'blahblahblaha'; elseif($myName == 'Dave') $myEmail = 'b;ahbahashdasd'; /* Commentasasdasda asd asdasdasd */ ?> '; ob_start(); highlight_string($string); $output = ob_get_contents(); ob_end_clean(); echo $output; ?> |
|
#3
|
|||
|
|||
|
RE: PHP Tutorial Making.
AHHHH!!!!
THANK-YOU! I was using " when it shoulda been '!! THANKS. I am extremely happy if you cant tell. |
![]() |
| Viewing: Codewalkers Forums > PHP Related > PHP Coding > PHP Tutorial Making. |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|