user8502591 user8502591 - 1 month ago 13
HTML Question

How to use php echo with a javascript or html function? Or php and html with document.write?

is it possible to use php echo with a JavaScript or html code inside it? Or html or php inside a JavaScript document.write? if you just type it nothing works!

Answer Source

Go here that is a converter! Or for your answer: Use this Code sample:Html to javascript:

<script type="text/javascript">

document.writeln(" <p>This is How!</p> ");

</script>

and html to php:

<?php
echo "<p>This is How!</p>\n";
?>