I’m trying to build my first Laravel application by following a few guides on the internet and I’m feeling I’m missing something obvious. Here is the code. Error BadMethodCallException in Builder….
Tag: laravel-5
General error: 20003 Adaptive Server connection timed out [20003] (severity 6)
Hi Following is error what I am getting:- I am trying to connect to MS-SQL-Server on windows from linux laravel 5.2 code snippet. There is firewall disable on windows machine. I am able to telnet on windows ip on ms sql default available port. I am not using free TDS, so this is not duplicate of TDS and even that
Laravel no logout option from menu after successfull login
Hope anyone else had the same issue and was able to solve this problem. I installed a fresh Laravel project and used php artisan make:auth to get the basic auth working. Strange thing is that after a successful login there is no logout link in the navbar. It should be available under the username (which has a pull down option)
Laravel container and shared instances
I am wondering how Laravel differentiates between singletons(shared instances) and concrete implementations that might be overwritten inside the container. The container has a bind method that looks like this: It also has a singleton method that calls this function but with the $shared argument always being true like so: The difference here being that although they both are bound in
Laravel delete() static call
I got this error: Non-static method IlluminateDatabaseEloquentModel::delete() should not be called statically, assuming $this from incompatible context Here is the code in my controller: Can someone explain what I am doing wrong and how to call it correctly? Answer You have this: But you should be doing this:
laravel errno 150 foreign key constraint is incorrectly formed
Can anybody help me to solve this problem? There are 3 tables with 2 foreign keys: Error after running migration: Answer In case of foreign keys, the referenced and referencing fields must have exactly the same data type. You create the id fields in both users and firms as signed integers. However, you create both foreign keys as unsigned integers,
Getting Controller does not exist after moving my controller to sub folder in laravel 5
I have created a resource full route which was pointing to a CRUD controller in App/Http/Controller/SeatController.php my Route in api.php Route::resource(‘websites’, ‘SeatController’); I wanted to put all controllers related to Seat inside a directory. I created a directory named Seat and I moved all of my controllers related to Seat to it. it’s path is : AppHttpControllersSeatSeatController before change it’s
Getting “Class ‘appHttpControllersController’ not found” in Laravel 5.1
I’m quite new to Laravel and when I am going through a tutorial when I encountered this error. This is my code in ‘testController.php’. And this is my ‘routes.php’. I am getting this error: Class ‘appHttpControllersController’ not found How can I fix this error? Answer Let’s go through this step by step. 1. Check autoload directive on composer.json Open composer.json
Laravel Eloquent, group by month/year
i’m trying to group my data by month and year. The output is : if i group only by month, i don’t know from which year belong this month, my expected output is : i want to do it in sql, not in php. Answer You can try as:
Best practice to render Laravel site in other language
Description I have a Laravel site is in English. I want to make it compatible with Dutch also. I start my homepage small, it only contain 3 sentences. which will render this Attempt I’ve installed this Laravel package and did all the installation steps from that repo. My routes, service provider, alias, middleware, resources/lang/ , and the laravellocalization.php are all