convert old('d') to $model->d in Laravel using regular expressions (RegEx)
While developing a website in PHP Laravel, I reused create.blade.php as edit.blade.php. So I need to edit some things, especially the input values.
In create.blade.php we use old('something') to retain the current <input> value by the user.
But in edit.blade.php we use $model->something to get the <input> value from the project backend.
So, I need to convert every old() to $model. But I am too lazy to rewrite all of them manually.