Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
Decision.
in routes.php :
Route::post('addcomment/{id}', array(
'as' => 'comment',
'uses' => '[email protected]'
));
{{ Form::model($post, array('action' => array('[email protected]', $post['id']))) }}
// Ваши данные
{{ Form::close() }}
public function add($id){
$data = Input::all();
$new = $id;
$data['post_id'] = $new;
$comment = Comment::add($data);
}
$comment = Comment::create([
//ваши данные
//и id:
'post_id' => $data['post_id']
]);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question