console.log phph
// Assuming you are wishing to log to the JS Console...
<?php
function consoleLog($msg) {
echo '<script type="text/javascript">' .
'console.log(' . $msg . ');</script>';
}
consoleLog('Hello, console!');
?><script>
console.log(<?= json_encode($foo); ?>);
</script>/*
console.log in php
*/
<?php
function consoleLog($message) {
echo '<script type="text/javascript">' .
'console.log(' . $message . ');</script>';
}
consoleLog('Hello, greppers!');
?>
Also in PHP:
- Class 'Intervention\Image\ImageServiceProvider' not found
- advanaced layout builder enfold custom post type
- codeigniter echo last query
- count characters php
- Illuminate\Contracts\Container\BindingResolutionException Target class [SlugController] does not exist.
- command to install laravel 7
- array value exists php
- encode by using base64 php
- display php errors on page
- creating a laravel project with composer
- clear routes laravel
- filter_var filter_validate_url
- datetime get current date php
- How can I install php7.4 on Ubuntu 18.04?
- clear laravel cache telescope
- check gettype is string php
- 12 hrs for preg match with single and double digit in php
- This domain is not registered with Tiny Cloud. Please see the quickstart guide or create an account.
- does $post work with date php
- count string php
- create project in laravel
- echo err in php
- Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, string given in
- check if php string looks like