Hi,
I am writing some php scripts that generates .html and .php pages. I just began writing the .php generating portion of the script and cannot figure out how to place either <? or ?> into a string without the php script itself thinking that there is a break and generating errors. The only way I can see to do this is: $string = "?" . ">" but that makes things difficult to read. Is there a way to escape the '?' character? Thanks.
-Chris
i dont understand the question. <? $string = "?>"; print $string; ?>
prints "?>" on the resulting page.. no parse errors
Well, since you put it that way, you can use "<SCRIPT LANGUAGE='PHP'></SCRIPT>", the only non-"?" way to put PHP code in a webpage.
If you're looking for a different answer, tell what exactly you are doing. Be more specific.