PHP

Snippets

array_map_recursive (source):
1
function array_map_recursive($callback, $array)
2
{
3
$func = function ($item) use (&$func, &$callback) {
4
return is_array($item) ? array_map($func, $item) : call_user_func($callback, $item);
5
};
6
7
return array_map($func, $array);
8
}
Copied!

PHPStorm

Mastering PhpStorm keyboard shortcuts #article - "PhpStorm has keyboard shortcuts for most of its commands related to editing, navigation, refactoring, debugging, and other tasks. Memorizing these hotkeys can help you stay more productive by keeping your hands on the keyboard."
Shortcut
Action
Double Ctrl
Run Anything
Execute commands, such as opening a project, launching a run/debug configuration, running a command-line utility, and so on. The available commands depend on the set of plugins and tools you have configured for your project.
Double Shift
Find anything related to PhpStorm or your project and open it, execute it, or jump to it.
⇧⌘A
Find a command and execute it, open a tool window or search for a setting.
⌘O ⇧⌘O ⌥⌘O
Find and jump to the desired class, file, or symbol.
⌘E
Select a recently opened file from the list.
⌥⏎
Improve or optimize a code construct.
⌃Space
Complete names of classes, methods, fields, and keywords within the visibility scope.
⌥↑ ⌥↓
Increase or decrease the scope of selection according to specific code constructs.
⌘/ ⌥⌘/
Comment out a line or block of code.
⇧⌘F7
Highlight usages in a file
Highlight all occurrences of the selected fragment in the current file.

Links

Slim - "Slim is a PHP micro framework that helps you quickly write simple yet powerful web applications and APIs."
Last modified 1yr ago
Copy link