Questions tagged as 'laravel-5'

1
answer

How to make a LIMIT in Laravel?

I need to show a certain amount of values in a view. I want to do something like SELECT * FROM tabla LIMIT 4 But I need to do it in Laravel     
asked by 03.10.2016 / 20:33
1
answer

Psr-4 Laravel Namespace

I am working with Laravel 5.1 in an app that is already running, but I am changing from modules to the repository pattern. "psr-4": { "app\": "app/", "Cms\": "app/cms" } The first one is the default namespace and the second is what...
asked by 13.09.2016 / 15:13
2
answers

TokenMismatchException in VerifyCsrfToken sending ajax by POST. ERROR 500

Hi, I have a problem with the csrftoken when making an ajax request. If I deactivate it in the kernel, protected $middlewareGroups = [ 'web' => [ \App\Http\Middleware\EncryptCookies::class, \Illuminate\Coo...
asked by 06.09.2016 / 18:51
1
answer

formValidation error with remote validator

My main problem was that I was trying to get a true / false from the controller to check the existence of an item in the database, (you can see it here) . The error was resolved, then I saw that one of the users, of the questions that they sugg...
asked by 26.11.2016 / 07:16
1
answer

Why do not Laracast / Flash messages run on laravel 5.2?

Install Laracast / Flash in my project developed in Laravel 5.2, everything is perfect, inserted and deleted and all that, but when I want to show a message, it does not do anything, that is, it makes the option but it does not show the message....
asked by 16.02.2016 / 07:28
1
answer

Check if a variable in a form is unique in 2 simultaneous models

You see, I have a form to register a new user, which has among its variables the email. These are the conditions you must meet:    'email' = > 'required | string | email | max: 255 | unique: users' The condition unique:user prev...
asked by 19.12.2018 / 21:04
1
answer

capture more than 1 value with ajax and laravel 5

I have in my view two selections with data, which I want to capture their values. I can do it with a select and the $.get method, but I do not know how to do it so I can capture two data and take it to a controller. I do not know if my...
asked by 12.07.2016 / 02:56
1
answer

Problem plunk laravel 5.5

I tried to count an array by plunk (), by means of a foreach, but for some reason it always remains in the first element and does not tell me the rest, should I use each ()? * @return \Illuminate\Http\Response */ public functi...
asked by 14.12.2018 / 02:23
1
answer

PROBLEM RELATIONSHIPS LARAVEL TABLES

I need your help, I am making a list of tables in laravel with migration, which tables are 'Products', 'inputs' and 'ProductProduct', the relationship or database would be from 1 to many (1 product has N inputs) but this error appears:    121...
asked by 04.11.2018 / 22:11
1
answer

Translate request to Eloquent Laravel

I have tried to translate this query to eloquen but until now I do not achieve it, does anyone know how I can do it? update usuarios set asignacion='gestion' where id='8';     
asked by 21.10.2018 / 02:03