PHP isset variable than jquery and javascript should work -


i want know if php variable not exists, want execute javascript.

for example-

<?php if(!isset($_request['myvar'])){    ?>    <script>    alert('variable not exist');    </script>    <?php } ?> 

is right way use javascript code in php extension file

do , work:

if (!isset($_request['myvar'])) {      echo "<script>alert('variable not exist');</script>"; } 

Comments

Popular posts from this blog

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -

Python ctypes access violation with const pointer arguments -