Laravel Migrations - Column already exists

I am running Laravel Framework version 5.2.45 and want to migrate my database migrations. I have two migrations. One is the standard 2014_10_12_100000_create_password_resets_table that comes out of the box and the other one is my newly created migra...
more »

2017-02-19 22:02 (1) Answers

Laravel - bestmomo filemanager

Welcome ! I have a problem. I integrated bestmomo filemanager with CKEditor and when i try to access it i have error NotFoundHttpException in RouteCollection.php line 161: Code is : <textarea name="editor"></textarea> <s...
more »

2017-02-19 21:02 (1) Answers

Laravel searching through relationships

I've tried to get help on this question before but I think people are either misinterpreting my question or don't quite understand what I'm trying to achieve, with Eloquent / Laravel. Each user has many categories. Each category has many articles. ...
more »

2017-02-19 15:02 (3) Answers

How to use barcode Scanner in web Application

I would like to use barcode scanner in my Laravel application. This is an online Point of Sale Application. I know that barcode scanner returns just a string and press Enter Button. But to capture this string I need to use a form and select the input...
more »

2017-02-19 10:02 (2) Answers

laravel- eloquent relationships

I have a courses table, a course hasMany sections and sections hasMany lectures and lectures hasMany comments. How should I define the relationship in the LectureComment model, if I have a comment id and I want to know its course name? table structu...
more »

2017-02-19 08:02 (1) Answers

Laravel issue with route and HTML form action

I'm having some trouble with my form, on submit I get the error 'Whoops, looks like something went wrong.'. I'm using Laravel 4.2, my routes look like this: Route::get('/', function() { return View::make('index'); }); Route::post('/', array(...
more »

2017-02-18 19:02 (1) Answers

Laravel show different date from my database

I have a problem in my project. When I store value in my database it works perfectly fine. But when I want to show the value it gives me an undefined date that is not stored in my database. Here In my database the created_at field value is 2017-02-...
more »

2017-02-18 12:02 (1) Answers

Unique value check during updating in laravel

I have tried to solve this problem. i have already look after several answer for this question and i have tried that solution but i have not success. Here is my controller function ... public function ProductCategoriesUpdate(Request $request, $cate...
more »

2017-02-18 12:02 (2) Answers

Undefined variable on view mailing in Laravel 5.4

Hi guys i'm trying to mail on my system and there's problem on view which is undifined variable of data. i'm trying to parsing data to view, but it seems to be problem. here is my code of mailing Mail::to($data['email'])->send(new TagihanMail(),[...
more »

2017-02-18 11:02 (2) Answers

How to "modify" a closure

I'm making a class to add metaboxes to Wordpress extending functionality of Metabox.io. Now you often have metaboxes with the same attributes (for example for the same post type). I want to group these so you don't have to duplicate those attribute...
more »

2017-02-18 09:02 (1) Answers

Retrieve Eloquent Model function in JavaScript

In Laravel, I have an Eloquent Model Person and a function getSomestringFromPerson() which is operating on the Model Person and returning a string. Now I have an AJAX request whose response is a collection of Persons. Until here I know what to do. ...
more »

2017-02-17 22:02 (1) Answers

VueJs and Laravel - multiple select fields

Using Laravel 5.4 and Vuejs 2.1 In code I have a select field with two input fields (quantity and stock) in tr (Table Row). Table Row with the fields can be dynamically added as much as user is needed, this is the code: <tbody id="loads-content"...
more »

2017-02-17 22:02 (1) Answers

Can't send reset password message in laravel 5

Expected response code 250 but got code "530", with message "530-5.5.1 Authentication Required. .env MAIL_DRIVER=smtp MAIL_HOST=smtp.gmail.com MAIL_PORT=587 MAIL_USERNAME="username@gmail.com" MAIL_PASSWORD="password" MAIL_ENCRYPTION=tls config/m...
more »

2017-02-17 20:02 (1) Answers

How to set where in relation Laravel?

I use the following construction for joining tables: with("attachments", "offers.publisher"). public function publisher() { return $this->belongsTo("App\User", "user_id", "id"); } How to join publisher relation only when offers....
more »

2017-02-17 19:02 (2) Answers

Post data always empty with PHPunit

I am using Lumen 5.4 and any PHPUnit tests that POST to applicable endpoints don't contain any data or headers. I've used both the json and regular call functions without success. Here is an example of some tests I've used: public function testLog...
more »

2017-02-17 18:02 (0) Answers

Laravel Zip Archive not downloading in browser

I am trying to zip a bunch of PDFs together and download in the browser, at the moment the PDF files are zipped and downloaded to the folder the PDFs are stored in, not via the users browser and into their download folder, I have a similar (and much ...
more »

2017-02-17 16:02 (1) Answers

Many to many relationship in Voyager Admin Panel

I get this error when I try to add a new item with the many to many relationship using the BREAD creator for voyager: SQLSTATE[23000]: Integrity constraint violation: 1052 Column 'id' in field list is ambiguous (SQL: select id from products...
more »

2017-02-17 14:02 (1) Answers

File upload through a modal using Ajax

I want to upload a file through a modal using Ajax. How can I do that? My modal: <div id="addBtn" class="modal fade in" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> <div class="modal-dialog"> <...
more »

2017-02-17 13:02 (1) Answers

Laravel Default Auth with Modals

I'm trying to modify laravel's default authentication system by using modal windows and by adding some new fields. So, I have a modal window to register a new users which looks like this: <!-- Modal Register area --> <div class="modal fade"...
more »

2017-02-17 11:02 (1) Answers

Save select value onchange Laravel

I am building a multi language app with Laravel, and I need the users to be able to log in and select their preferred language(table "languages") from a select field and store in the database("language_id" in table "users") just by selecting it from ...
more »

2017-02-17 11:02 (3) Answers

Class App Not Found (Laravel 5.4)

I've got a weird error. I want to just insert the remark field into the database but it seems that it doesn't work. Please help. Error says: Class 'App\Job' not found Jobs.php namespace App; use Illuminate\Database\Eloquent\Model; class Job exte...
more »

2017-02-17 10:02 (1) Answers