Skip to content

Instantly share code, notes, and snippets.

@sorokadima
Last active March 2, 2020 12:58
Show Gist options
  • Save sorokadima/818efec50787f0a51ef1515cc128bfbc to your computer and use it in GitHub Desktop.
Save sorokadima/818efec50787f0a51ef1515cc128bfbc to your computer and use it in GitHub Desktop.
intellij idea Liva Templates (Pre PHP, PHPStorm, Var dump PHP live template, intellij idea, console.log, console log, phpstorm, php storm, rubymine, ruby mine, webstorm, web storm)
<?php
echo __FILE__ . ':' . __LINE__ . '<pre>' . PHP_EOL;
echo print_r('hello world', true);
exit;
?>
// $END$ - куди поставити курсор
console.log('', $END$);
<?php
// touch /tmp/phplog.log && chmod 777 /tmp/phplog.log
// sudo touch /tmp/phplog.log && sudo chmod 777 /tmp/phplog.log # (sudo)
$v = 'test';
file_put_contents('/tmp/phplog.log', file_get_contents('/tmp/phplog.log') . PHP_EOL . date('m/d/Y h:i:s a', time()). ' ' . __FILE__ . ':' . __LINE__ . PHP_EOL . print_r($v, true) . PHP_EOL);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment