Trending questions in Laravel

0 votes
1 answer

How to “Refresh” the User object in Laravel?

Hello @kartik, You can update the cache object ...READ MORE

Sep 30, 2020 in Laravel by Niroj
• 82,880 points
2,703 views
0 votes
1 answer

How to return database table name in Laravel?

Hello @kartik, There is a public getTable() method ...READ MORE

Sep 24, 2020 in Laravel by Niroj
• 82,880 points
2,958 views
0 votes
1 answer

Error: reverting ./composer.json to its original content

Hello @kartik, I used to use this: composer require ...READ MORE

Sep 11, 2020 in Laravel by Niroj
• 82,880 points
3,493 views
0 votes
1 answer

How to get the Last Inserted Id Using Laravel Eloquent?

Hello @kartik, Firstly create an object, Then set ...READ MORE

Nov 11, 2020 in Laravel by Niroj
• 82,880 points
860 views
0 votes
1 answer

How to run migrations on another database in laravel?

Hello @kartik, If you place database config on ...READ MORE

Sep 28, 2020 in Laravel by Niroj
• 82,880 points
2,735 views
0 votes
1 answer

How to change Yarn default packages directory?

Hello @kartik, You can create a .yarnrc file with the ...READ MORE

Nov 12, 2020 in Laravel by Niroj
• 82,880 points
732 views
0 votes
0 answers

how to create exception in react router using Route::get('/{path?}', 'IndexController@index')->name('index') ->where('path', '.*');

I am using react routers within Laravel ...READ MORE

Nov 15, 2020 in Laravel by datso
• 120 points

recategorized Nov 16, 2020 by Niroj 664 views
0 votes
1 answer

Error:Missing argument 2 for App\Http\Controllers\EventsController::remindHelper()

Hello @kartik, When you define this route: Route::get('events/{id}/remind', [ 'as' ...READ MORE

Nov 12, 2020 in Laravel by Niroj
• 82,880 points
632 views
0 votes
1 answer

How to include csrf_token() in an external js file in Laravel?

Hello @kartik, add <meta> tag with the token to the ...READ MORE

Oct 21, 2020 in Laravel by Niroj
• 82,880 points
1,565 views
0 votes
1 answer

How to get a list of registered route paths in Laravel?

Hello, Route::getRoutes() returns a RouteCollection. On each element, you can ...READ MORE

Nov 11, 2020 in Laravel by Niroj
• 82,880 points
619 views
0 votes
1 answer

How to run some migrations on new user's database after its creation?

Hello, If you place database config on the database.php file, ...READ MORE

Nov 12, 2020 in Laravel by Niroj
• 82,880 points
586 views
0 votes
1 answer

How to get a variable name as a string in PHP?

Hello @kartik, You can use this: function varName( $v ...READ MORE

Sep 29, 2020 in Laravel by Niroj
• 82,880 points
2,438 views
0 votes
1 answer

What is the use of the Eloquent cursor() method in Laravel?

Hello, The cursor method allows us to iterate ...READ MORE

Mar 20, 2020 in Laravel by Niroj
• 82,880 points
10,730 views
0 votes
1 answer

Error messages: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed

Hello @kartik, set MAIL_ENCRYPTION= in .env file. and it worked fine ...READ MORE

Oct 23, 2020 in Laravel by Niroj
• 82,880 points
1,321 views
0 votes
1 answer

How to Check for a Specific Type of Object in PHP?

Hello @kartik, Use: bool is_a ( object $object ...READ MORE

Oct 29, 2020 in Laravel by Niroj
• 82,880 points
957 views
0 votes
1 answer

How can I specify the required Node.js version in package.json?

Hello @kartik, I think you can use the ...READ MORE

Jul 20, 2020 in Laravel by Niroj
• 82,880 points
5,238 views
0 votes
1 answer

Error: Class 'TestCase' not found in D:\xampp\htdocs\laravel\app\tests\ExampleTest.php on line 3 ,

Hello @kartik, Run following command in your project's ...READ MORE

Sep 28, 2020 in Laravel by Niroj
• 82,880 points
2,239 views
0 votes
1 answer

How to remove composer sdk from laravel packages

Use  two blade page,one for create and other ...READ MORE

Oct 15, 2020 in Laravel by Niroj
• 82,880 points
1,468 views
0 votes
1 answer

How do I write to the console from a Laravel Controller?

Hello @kartik, This can be done with the ...READ MORE

Oct 29, 2020 in Laravel by Niroj
• 82,880 points
765 views
0 votes
1 answer

What is reverse routing in Laravel?

 Laravel reverse routing is generating URL's based ...READ MORE

Mar 17, 2020 in Laravel by Niraj
10,507 views
0 votes
1 answer

How to get all pending jobs in laravel queue on redis?

Hello @kartik, Here is the way I do ...READ MORE

Apr 6, 2020 in Laravel by Niroj
• 82,880 points
9,538 views
0 votes
1 answer

How to create a laravel hashed password?

Hii @kartik, Hashing A Password Using Bcrypt in Laravel: $password ...READ MORE

Aug 4, 2020 in Laravel by Niroj
• 82,880 points
4,332 views
0 votes
1 answer

How to Install Laravel without using Composer?

Hello @kartik, If you really wanted to, you ...READ MORE

Aug 10, 2020 in Laravel by Niroj
• 82,880 points
4,011 views
0 votes
1 answer

How to run specific migration in laravel?

Hello @kartik, Use this command: php artisan migrate --path=/database/migrations/my_migration.php  And ...READ MORE

Aug 10, 2020 in Laravel by Niroj
• 82,880 points
3,974 views
0 votes
1 answer

Using Artisan::call() to pass non-option arguments

Hello @kartik, Use: Artisan::call('db:migrate', ['' => 'mymigration', '--table' => ...READ MORE

Sep 28, 2020 in Laravel by Niroj
• 82,880 points
1,878 views
0 votes
1 answer

Error:Composer Out of memory in Laravel?

Hey @kartik, This Error  happens in almost all ...READ MORE

Mar 30, 2020 in Laravel by Niroj
• 82,880 points
9,656 views
0 votes
1 answer

How to create Eloquent model with relationship?

Hello @kartik, First, you have to create relation ...READ MORE

Oct 28, 2020 in Laravel by Niroj
• 82,880 points
453 views
0 votes
1 answer

Error:Swift_TransportException Expected response code 220 but got code "", with message ""

Hello @kartik, This problem can generally occur when ...READ MORE

Jul 30, 2020 in Laravel by Niroj
• 82,880 points
4,330 views
0 votes
1 answer

How to getting the location from an IP address?

Hello @kartik, You could download a free GeoIP ...READ MORE

Sep 29, 2020 in Laravel by Niroj
• 82,880 points
1,372 views
0 votes
1 answer

How could i create carbon object from given datetime structure?

Hello @kartik, Use Carbon::parse('2020-09-25 14:26');, it will return a Carbon object. Hope it ...READ MORE

Sep 25, 2020 in Laravel by Niroj
• 82,880 points
1,544 views
0 votes
1 answer

Laravel Pagination links not including other GET parameters

Hello @kartik, I think you should use this ...READ MORE

Aug 4, 2020 in Laravel by Niroj
• 82,880 points
3,773 views
0 votes
1 answer

Error:ErrorException in Filesystem.php

Hello @kartik, Try this: chmod -R gu+w storage chmod -R ...READ MORE

Sep 25, 2020 in Laravel by Niroj
• 82,880 points
1,497 views
0 votes
1 answer

Error:ReflectionException: Class ClassName does not exist - Laravel

Hello @kartik, Perform a composer update, then composer dump-autoload. If the ...READ MORE

Aug 11, 2020 in Laravel by Niroj
• 82,880 points
3,103 views
0 votes
0 answers

How do I access to a variable inside a function?

I mean,I have public class MyClass{ ...READ MORE

Sep 21, 2020 in Laravel by aakash
• 230 points

edited Sep 21, 2020 by Niroj 1,344 views
0 votes
1 answer

How can I query raw via Eloquent?

Hello @kartik, You may try this: // query can't ...READ MORE

Sep 24, 2020 in Laravel by Niroj
• 82,880 points
1,164 views
+1 vote
1 answer

Error:file_put_contents(meta/services.json): failed to open stream: Permission denied?

Hello @kartik, Below steps helped me fix the ...READ MORE

Apr 3, 2020 in Laravel by Niroj
• 82,880 points
8,616 views
0 votes
1 answer

How change view folder in Laravel5?

Hello @kartik, See line 16 of config/view.php (the "View Storage ...READ MORE

Sep 25, 2020 in Laravel by Niroj
• 82,880 points
1,078 views
0 votes
1 answer

How to only use created_at in Laravel?

Hello @kartik, Eloquent does not provide such functionality ...READ MORE

Aug 11, 2020 in Laravel by Niroj
• 82,880 points
2,953 views
0 votes
1 answer

How to generating a random password in php?

Hello @kartik, Try this (use strlen instead of count, because count on a ...READ MORE

Sep 29, 2020 in Laravel by Niroj
• 82,880 points
748 views
0 votes
1 answer

How can we allow the funtion to have access to $slug?

Hello @kartik, You have to use use to pass variables ...READ MORE

Sep 30, 2020 in Laravel by Niroj
• 82,880 points
680 views
0 votes
1 answer

How to populating a database in a Laravel migration file?

Hello @kartik, Don't put the DB::insert() inside of ...READ MORE

Aug 4, 2020 in Laravel by Niroj
• 82,880 points
3,070 views
0 votes
1 answer

Error:“The page has expired due to inactivity” - Laravel 5.5

Hello @kartik, Make sure you have already added ...READ MORE

Aug 4, 2020 in Laravel by Niroj
• 82,880 points
3,041 views
0 votes
1 answer

How can I build a condition based query in Laravel?

Hello @kartik, Try this: $query = DB::table('node'); if ($published == ...READ MORE

Sep 28, 2020 in Laravel by Niroj
• 82,880 points
657 views
0 votes
1 answer

How to perform a delete operation on a Model?

Hello @kartik, You can put this code for ...READ MORE

Sep 30, 2020 in Laravel by Niroj
• 82,880 points
472 views
0 votes
1 answer

Error: “No scheduled commands are ready to run.” in Laravel?

Hello @kartik, Run php artisan and see if your commands ...READ MORE

Apr 6, 2020 in Laravel by Niroj
• 82,880 points
7,972 views
0 votes
1 answer

How to get client IP address in Laravel >5?

Hello @kartik, Use request()->ip(). Since Laravel 5 it's advised/good practice ...READ MORE

Sep 11, 2020 in Laravel by Niroj
• 82,880 points
773 views
0 votes
0 answers

I am unable to send emails on my php script

I am unable to send emails from ...READ MORE

Sep 6, 2020 in Laravel by Titus
• 160 points

recategorized Sep 6, 2020 by Niroj 1,006 views
0 votes
1 answer

How to pass data to view in Laravel?

Hello @kartik, You can pass data to the ...READ MORE

Sep 11, 2020 in Laravel by Niroj
• 82,880 points
684 views
0 votes
1 answer

How do I catch exceptions / missing pages in Laravel 5?

Hello @kartik, In Laravel 5 you can catch ...READ MORE

Aug 11, 2020 in Laravel by Niroj
• 82,880 points
2,006 views