Most voted "laravel" questions
Laravel is an open-source framework for developing web applications and services with PHP. Before asking consult the official documentation of Laravel.
Learn more…2,777 questions
Sort by count of
-
1
votes1
answer269
viewsException url in Laravel token?
In my project I need to release a url for a service rest I’m implementing, only I’m not getting to make the exception of token for this route, since I will not receive you in the service. In the…
-
1
votes1
answer167
viewsProblem with Laravel API in production
I have deployed an API in Laravel. The problem that is occurring is the following: the online API always returns me '200 ok', without at least getting to the login controller. With this same API, I…
-
1
votes1
answer157
viewsLaravel 4.2 and Ajax image upload
I am trying to make an image upload, to save along with the rest of the fields, but when I press the save button, the picture field will empty.. This is the Form <div class="panel"> <div…
-
1
votes0
answers282
views'SET ANSI_WARNINGS ON' Orange 5.4
I am using Laravel 5.4 with 2 connections, one of them is just to access some Views of a Sql Server database, and one of them makes a LINKED SERVER which forces me to set some settings before making…
-
1
votes2
answers1121
viewsDelete record with Laravel via AJAX
I am developing an application in PHP with Laravel and I have in my Alunoscontroller and following method: public function destroy($id) { $aluno = new Aluno(); $result =…
-
1
votes1
answer1505
viewsError "Warning: putenv() has been disabled for security reasons"
When I upload to production I get these errors: Warning: putenv() has been disabled for security reasons in /home/httpd/htdocs/telekobr/site/vendor/vlucas/phpdotenv/src/Dotenv.php on line 86…
-
1
votes1
answer98
viewsLaravel Error Count() Laravel/datatables 5.2 PHP -v 7.2
The following error with datatables: Function:…
laravelasked 6 years, 4 months ago iMurilo Cruz 11 -
1
votes1
answer31
viewsSum null value Laravel
I am trying to sum the following with Query Builder, but if one of the values is null and does not sum DB::raw("estudantes_carga_horaria.dias_letivos_oferecidos +…
-
1
votes1
answer27
viewsDisable button after redirect
I have the following situation: A screen (Tela1) where the user chooses the button referring to a Set (an entity of my program), he clicks and opens a registration form for that Set. By clicking…
-
1
votes1
answer1780
viewsHow can I change the attribute of a column with Laravel Migrations
In my database I created using the Laravel Migrations I have a column called celphone which unfortunately did not add the attribute ->nullable() when I created it, now that the base is already in…
-
1
votes1
answer112
viewsLARAVEL - How to share images between projects
I have several projects Laravel on the same server. Often, I need to use employee photos and, as I have programmed, I copy the photos from the directory public/assets/images from an existing project…
-
1
votes2
answers1263
viewsSponse() in XML with Laravel
I have studied about developing Apis with Laravel, a quick question, it is possible to return an XML instead of a json? instead of doing: return response()->json($json); do something like: return…
-
1
votes0
answers1042
viewsMulti-level Treeview Menu does not work in Adminlte
Problem: I’m using the template Adminlte 2 (very good template! ) in the project that uses the Framework Laravel. I was able to include all the files and configure the layout to be displayed on…
-
1
votes1
answer372
viewsRun a task at a given time
I’m developing a system of deadlines and alerts. The user will register a deadline, date and time of the deadline and define if he wants to receive the alert 1, 2 or 3 hours in advance. How could I…
-
1
votes1
answer28
viewsConstraining Eager Loads returning unfiltered
I have a problem with Eager loading on Laravel 5.4.24. Following the documentation, I added the code: $profiles = Profile::with(['platforms' => function ($query) { $query->where('name', 'PC');…
-
1
votes1
answer639
viewscompile mix Standard 5.4
Hello, I have a problem in Laravel 5.4 I am trying to put a personal js library of mine and I am not getting and remove Vue my package.json { "private": true, "scripts": { "dev": "npm run…
-
1
votes1
answer488
viewsTreatment of HTML co Guzzle Laravel?
I have an application that needs to read external data, or another URL, I’m doing this necessarily with Guzzle, but when I convert to json to mount the array with the data, it returns me null. use…
-
1
votes1
answer94
viewsA single application with many databases
I have an application with the Laravel framework that I created many subdomains to access. Today I make a separate environment for each one, but the files in each of them will be the same. My…
-
1
votes1
answer587
viewsLaravel paging with search filter?
I have on my home screen a search filter, when I perform the search is sent by POST the filter data and I can’t get the pagination link redirected with the search filters. Every time I have filtered…
laravelasked 7 years, 4 months ago Matheus Hahn 57 -
1
votes1
answer728
viewsDynamically add form fields in Laravel
I have a company registration form, within this register, the company can have 'n' certificates. These certificates should be added to the form as required. How can I do this in Laravel? I’ve tried…
-
1
votes1
answer467
viewsHow to create a relationship between 3 Laravel tables?
I own 3 tables that it is necessary to make Join’s to access the information. By the relationship of the Laravel I can create simple relationships, like belongsTo. I’m trying to access the…
-
1
votes0
answers550
viewsLaravel - Help with Authentication
I’m using Laravel 5.3 and I’m having a headache with Authentication. I’m using make:auth. So far it’s simple, but let’s look at the scenario below. In my project, when I log in I send the email and…
-
1
votes1
answer2010
viewsHelp with relationships in the Flat
I am really enjoying using Laravel 5.4 and I have some doubts about the relationships and how best to use it have the tables evento -id -nome categorias_evento -id -id_evento -nome lotes_evento -id…
-
1
votes1
answer856
viewsTypeahead js Autocomplete in Laravel?
I am implementing the AUTOCOMPLETE typeahead js bootstrap in my application Laravel and works perfectly, currently it returns only the name of the municipality table municipalities, only from this…
-
1
votes1
answer165
viewsRequest $request in object-oriented PHP
I’m doing some PHP OO exercises and came across some functions that call a class before the variable. But I didn’t really understand why. For example: public function Exemplo(Request $request,…
-
1
votes0
answers207
viewsProblems with DOM PDF PHP
I am generating a document and this error appears: Call to Undefined method Dompdf Framedecorator Tablerowgroup::get_cellmap() My printing method is developed so: public function…
-
1
votes0
answers250
viewsIs there a Sqlite PHP simultaneous connection limit ?
I currently use Mysql on my server with a limit of 50 simultaneous connections.. thought to use SQL Server which in turn has no simultaneous connection limit but is very expensive!!.. So I thought…
-
1
votes1
answer100
viewsFilter records within one month interval
I have several items sold in a month and would like to display only the items sold in the current month. Example: in September I had a total of 30 items sold, and in August, 20 items. How do I take…
-
1
votes1
answer733
viewsChat with warning notification in Lockable
I’m developing a chat with Laravel, and follow this tutorial. The chat is working fine, but wanted to know how to appear a notification of this type: When a message is sent to a user and has not…
-
1
votes0
answers602
viewsSlow mailing with Laravel?
I’m doing some mass mail testing but I’m finding it a bit slow the process being done with Laravel. The reason I was finding sending it slow is that I worked in a company where on average 50~60,000…
-
1
votes1
answer678
viewsHow to delete a record from a table in the view without deleting from the database
I am developing a system at the didactic level and in my view I have a table that displays the data of an employee registered by the user. In the view has the edit and delete buttons, only that the…
-
1
votes0
answers77
viewsHow to simulate an ob_flush() in Laravel?
I have a form on which I upload. And sometimes the upload file is large. My site is on AWS using Load Balancer. Load Balancer expects a response from the request at a given time. However, the…
laravelasked 6 years, 1 month ago Diego Souza 16,524 -
1
votes1
answer89
viewsInstantiate class within bootstrap/start.php file Laravel 4.2?
I have an app running Laravel 4.2, I have a class that takes care of IP's in a blacklist, and this one is safe on the bench. I need that when a user accesses my application the system validates if…
-
1
votes2
answers676
viewsSeeder Laravel with 2 relationships
I need a help, I want to create, for each Category, one Local and for each Local, one City, but when running the Eds, the error occurs below: Call to Undefined method Illuminate Database Query…
laravelasked 7 years, 4 months ago Eduardo Paludo 733 -
1
votes2
answers976
viewsResult field name instead of id on Laravel 5?
I have a relationship in Laravel but when I make an appointment comes the id and not the name of the field. Model Evento public function tipo_evento() { return…
-
1
votes0
answers99
viewsHow to pass a query to Eloquent?
I’m trying to translate a SQL for Eloquent, where she receives an id ($myid) and returns the combinations of clothing, IE, I have a table clothes and I have another table combinations_clothes and in…
-
1
votes0
answers246
viewsMigration with multiple banks in Laravel
I am trying to create a Migration that has a foreign key referencing the id of a table from another database, both Mysql. Follows the code: //config/database.php 'mysql' => [ 'driver' =>…
-
1
votes2
answers44
viewsError using Many to Many
I have a group of Users who have relationship Many To Many, to create this relationship I did a function beLongsToMany within the model Usuarios. But every time I call this function I get the…
-
1
votes1
answer58
viewsHow do I store 2 SQL queries in a single variable?
Good afternoon guys, I am trying to make 2 queries in my application and I want both to be stored in a single variable, can I do ? if yes as I do ? Consultation 1: $usuarios = DB::table('users')…
laravelasked 7 years, 4 months ago Bruno Santos 103 -
1
votes0
answers393
viewsInvalid request (Unexpected EOF) - Orange 5.4
I’m having a problem using Laravel 5.4, suddenly the site stopped working (locally) and gives this error in the server (cmd) and the site does not load. In the browser console error 500 appears when…
-
1
votes0
answers21
viewsFind file that generated CSRF TOKEN error
I set up the file handler for whenever any error occurs on the server, I receive an email with the details. So today I got an email with the following error: array(3) { ["message"]=> string(0) ""…
-
1
votes1
answer1107
viewsRegistration in more than one table with Laravel
So, I have 3 tables (doctors, addresses and phones), first I do the insertion in the medical table using the store method that is in its own controller, and I take the id created for it and insert…
-
1
votes2
answers940
viewsLaravel eloquent returning array of array
I have this consultation using eloquent $data= \App\Logs::select('id', 'created_at') ->get() ->groupBy(function($val) { return Carbon::parse($val->created_at)->format('d-M-');…
-
1
votes1
answer414
viewsSave in two tables with dynamic inputs (one-to-Many) Laravel
I couldn’t make a mistake: Errorexception in Parameterbag.php line 88: array_key_exists(): The first argument should be either a string or an integer My Controller: public function store(Request…
-
1
votes1
answer2283
viewsSymbolic link does not work on Laravel
I’m trying to make a folder inside the directory public Storage of Laravel, but I was unsuccessful. The folder to be made public is on the way: project/storage/app/images Yes, outside the public.…
-
1
votes1
answer123
viewsCustomizing Laravel Authentication Hash
Next, I have a specific database with specific columns and a specific Hash method, I am migrating to the following Laravel multi-tenancy structure. I would like to know if there is any way to make…
-
1
votes1
answer243
viewsAccess the Laravel API route 5.7
I’m learning to use Laravel as a Rest API and went to test by Postman a route that returns a string, but I can’t find an error. Returns not found. Address: http://127.0.0.1:8000/api/dot/ <?php…
-
1
votes1
answer244
viewsLaravel 5.4 - Display all phones of each result
I have the table convenios and telefones, each convenio has one or more telefones and a screen where are listed all convenios, I need you to come along with all the phones related to each meeting. I…
-
1
votes1
answer163
viewsTransform 2 php array into a single array
I have 2 Arrays: "val" => { "0": "2" "1": "4" "2": "6" "3": null "4": null } "p" => { "0": "4" "1": "5" "2": "7" "3": "8" "4": "9" } Before that I want to take the elements of array val which…
-
1
votes1
answer1781
viewsLaravel: How to recover last entry in mysql database by your foreign key?
I am working on a database that has only as a reference to your foreign key, and I need to locate the last record according to your foreign key.
laravelasked 5 years, 11 months ago Richard Carlos 91