Extract Variable refactoring | PhpStprm
The Extract Variable refactoring wraps a selected expression into a variable. It adds a new variable declaration and uses the expression as an initializer. Select an expression and press Ctrl Alt V (Refactor | Extract/Introduce | Variable).
#phpstorm