Data dodania Pytanie
2017-11-04 14:11 Intercept dynamic function calls (like laravel HasAttribute trait) »
Consider the follow class A: public class A { //... } and the following snippet: $a = new A(); $value = $a->getFooValue(); As you can see g...
(1) odpowiedzi
2017-11-04 08:11 laravel Form Request = if button was clicked »
I need to know which button was clicked inside a request form on laravel since i have Save and Update buttons. App\Http\Requests\RegistrationRequest....
(2) odpowiedzi
2017-11-04 02:11 `composer update` doesn't update to the latest version »
In my composer.json I have "require": { . . . "unisharp/laravel-filemanager": "~1.8" } Currently, the latest version is v1.8.2.2 and after ...
(1) odpowiedzi
2017-11-04 00:11 how to check if a specific array key is exist in multidimensional array »
if i'm accessing an index like that $var = $final_Length_Array[1][0]['id']; how to check whether the "id" key index exist in the array or not. i t...
(1) odpowiedzi
2017-11-03 22:11 Laravel 5.5 Login errors not showing up »
Here is my login.blade.php @if(Session::get('errors')||count( $errors ) > 0) @foreach ($errors->all() as $error) <h1>{{ $error }...
(3) odpowiedzi
2017-11-03 20:11 A foreign key constraint fails using save() but not failing with create() in Lumen »
I am trying to post an object however I am getting the following error when using save() function: Cannot add or update a child row: a foreign key...
(3) odpowiedzi
2017-11-03 19:11 Laravel - Save multiple data to one column in database »
I have a student form on Laravel 5.5 where users can add as many hobbies as they can. Each hobby has Title, Description & Image. I want to save al...
(2) odpowiedzi
2017-11-03 19:11 Get user with specific age using date from database and carbon »
I am doing requests when I want to get users with specific age. But I do not know how to get users from database. For example if user has 19 yo, I wan...
(1) odpowiedzi
2017-11-03 17:11 How to build a table with jQuery datatables with row child »
I'm using jQuery datatable with Ajax. Server with Laravel returns a JSON with the format: { "draw":0, "recordsTotal":201 ,"recordsFiltered":201, "dat...
(0) odpowiedzi
2017-11-03 14:11 Laravel return view not sending data, but echo view works »
I've stumbled across a rather strange issue. return view('myview', $data); works for everything except one unique set of route parameters. For example...
(1) odpowiedzi
2017-11-03 12:11 Laravel 5.5 | Tags only appear in the last post? »
I want to display tags of the posts , but when I tried to display, tags only appear in the last post. Here my codes; BlogController; public functio...
(1) odpowiedzi
2017-11-02 21:11 VueJS SPA and Laravel API on different servers, how to handle CSRF? »
When loading a page where the JS and PHP are delivered from the same server, it's quite easy to simply do: <meta name="csrf-token" content="{{ csr...
(1) odpowiedzi
2017-11-02 20:11 Reference an object property with a variable »
I need to reference an object property with a variable like this: $user = User::find( 1 ); $mobile = $user->getData( 'phone.mobile' ); The value...
(1) odpowiedzi
2017-11-02 18:11 Designing a database for personal project »
I am pretty new to designing databases, and currently, I am working on a substantial big project of mine which requires a pretty big database. Here fo...
(1) odpowiedzi
2017-11-02 17:11 Custom Middleware - Too Many Redirects - Laravel »
I want to create a custom middleware that only if the user is authenticated and the email is a certain email to access the /admin page. Although, whe...
(1) odpowiedzi
2017-11-02 11:11 Laravel - Socket.io chat system »
I'm currently working on a project where two users can chat between each other. I just got socket.io working without laravel, Currently there is no ch...
(1) odpowiedzi
2017-11-02 10:11 Laravel, using model method as property »
I am new to Laravel and playing around with it. Sorry if this is a silly question. I just could not figure out how eloquent relationships work. For ex...
(1) odpowiedzi
2017-11-01 23:11 Laravel duplicated queries from blade directive »
I am getting duplicated queries from using a Blade directive. I am checking a user's role, and then displaying data in a table, so the query repeats i...
(3) odpowiedzi
2017-11-01 16:11 Laravel: use extended controller or Traits or something else? »
To maintain my Laravel application and save myself from a lot of duplicate code I have made the following solution: BaseController class BaseControl...
(2) odpowiedzi
2017-11-01 14:11 Check value from another table and based on the value save in current »
I want to check what value has column in another table and based on that value to save in current table. Here is the controller so you can get what I ...
(2) odpowiedzi
2017-11-01 10:11 Will laravel database transaction lock table »
I use laravel5.5's database transaction for online payment applicaiton. I have a company_account table to record each payment(type, amount, create_at...
(3) odpowiedzi
2017-11-01 10:11 How I can store url in database Laravel »
In laravel 5.4 , When I want to use url I've to config in web.php ex Route::get('/test/{id}', function () { return view('frontend/test/{id}'); }...
(2) odpowiedzi
2017-11-01 08:11 Laravel collection order similar to DB FIELD »
I have a query with following order $query->orderByRaw("FIELD(type, 'red', 'green', 'aqua') ASC"); This will order items not alphabetically, but ...
(1) odpowiedzi
2017-10-31 21:10 Saving 2D array into Laravel session »
I'm trying to convert a pure PHP code to Laravel. This code works with session extensively - here is the simplified part of the code (please ignore sy...
(1) odpowiedzi
2017-10-31 16:10 Laravel dynamic routing with interface »
I have an app which requires different HomeControllerdepending on subdomain I'm using. So for example domain.mydomain.com/news should point to one con...
(1) odpowiedzi
2017-10-31 16:10 How reduce Redirect condition size in Laravel? »
I'm trying to make things more simple in my Laravel application. Therefore I'm wondering how's it possible to NOT redirect the Client if one of my fun...
(1) odpowiedzi
2017-10-31 14:10 Keep getting 401 unauthorized 'invalid credentials' Laravel Passport »
I have generated some demo user through seeders. I can login those user by oauth/token. But when I create new user. I can't login anymore. It always g...
(1) odpowiedzi
2017-10-31 13:10 Query All Records Where Many to Many Relationship Is Certain Value »
I have an Advisor class that has a many-to-many relationship with and Events class. The relationship is defined as: public function events() { re...
(1) odpowiedzi
2017-10-31 13:10 OctoberCMS - How to call a function inside a component »
I am building an order form and I warn you in advance I am a noob with backend dev :) So my first component takes all data from the order form and sa...
(1) odpowiedzi
2017-10-30 11:10 Nginx. Laravel. How to set up multiple endpoints in subfolders »
I have such a project structure <root>/public/laravel_app/index.php — Laravel index file <root>/public/index.php — Cra...
(2) odpowiedzi
2017-10-30 04:10 Laravel not navigating to url based on database id »
I am attempting to navigate to a product page with laravel. The URL gets an id which is obtained from the database id which it uses to display the pro...
(3) odpowiedzi
2017-10-30 04:10 Best Location In Laravel For Third-Party API Connection »
I'm writing a Laravel application using one or more third-party APIs when it suddenly dawned on me. Where is the best place within the Laravel applica...
(0) odpowiedzi
2017-10-29 16:10 Laravel 5.4, Cancel subscription gives error »
I have this form: <form action="{{route('subscription.cancel')}}" method="post"> {{csrf_field()}} <button type="submit">Cancel&lt...
(1) odpowiedzi
2017-10-29 16:10 Laravel/Eloquent conditions on subproperties don't apply »
I have the following models: Client belongsToMany(Group) Group belongsToMany(Client) What I wanted is an array of all groups, where each gro...
(1) odpowiedzi
2017-10-29 12:10 ReflectionFunction Not found in laravel »
To find where a function is defined in a Laravel application I'm trying to do this: Inside App\Http\Controllers Namespace: $reflFunc = new Reflect...
(3) odpowiedzi