如何在使用LUMEN

流明不使用Collective / html。当我尝试使用表单操作时: 我收到错误信息** 调用未定义的函数action() 如何在路线中将表单发送到特定方法?

我有控制器和存储方法。 我已经路由到我的控制器 我有表格,想指出具体方法

我的表单:

<form action="{{ action('LicensesController@store') }}" method='POST'>

但我收到错误消息未定义函数action()的调用

我的控制器的方法:

    // saving to database
    public function store(Request $request){
    }

我的路线: 在/ licenses / create页面上,我有表单,并希望将其发送到@store方法(我将其保存到数据库中

Route::get('/licenses','LicensesController@index');
Route::post('/licenses','LicensesController@store');
Route::get('/licenses/create','LicensesController@create');
Route::get('/licenses/{licence}','LicensesController@show');

如何使用LUMEN(很多Laravel功能不起作用)将表单发送到路线中的特定方法

我可以使用

<form action="/licenses" method='POST'>

它是可行的,因为路由将触发存储方法,但是我认为有更适当的方法,更雄辩的方法,您可以帮助我找到它

a85935935 回答:如何在使用LUMEN

暂时没有好的解决方案,如果你有好的解决方案,请发邮件至:iooj@foxmail.com
本文链接:https://www.f2er.com/3118894.html

大家都在问