How can I put a php statement between quotes, inside php?
I want to call str_replace(), and the first argument is a string that is a PHP statement, that I want to replace).
The string is: <?php echo $_GET['number'];?>
Now, how do I put that 开发者_如何学JAVAinto quotes? Is it possible? I just want that to be treated as a string.
Thank you!
Is this all you're trying to do?
echo '<?php echo $_GET["number"];?>';
I think we're a little confused.
If you want to output that exact text to an html page just do
<?php
echo htmlentities('<?php echo $_GET["number"];?>');
I may have misunderstood what you wanted though...
精彩评论