I'm trying to setup cartalyst/converter on laravel 5.6 Their link is here: https://cartalyst.com/manual/converter/2.0
I'm following official instruction and getting
Call to undefined method Illuminate\Foundation\Application::share()
I feel like Cartalyst\Converter\Laravel\ConverterServiceProvider is not livable.
How else can I install it?
They have "Native" way, but in laravel case where would I put their "native" code?
Illuminate\Foundation\Application::share() method was removed in Laravel 5.4, in favor of the singleton() method.
Do you need to use v2.0 of this package? 3.0 was released specifically to stay up-to-date with Laravel. I suggest using the most recent version instead of the 2.0 branch.
https://cartalyst.com/manual/converter/3.0
Related
I'm new to laravel and I'm having some issues in generating an api documentation (SwaggerAPI, OpenAPI, Postman, whatever it works). I am upgrading a laravel application and got stuck got a few things I need to do solve with the latest version (9.x)
I've followed the steps installing the most popular libraries but I failed getting and error because of lumen is a higher version that is not supported. I also cannot run artistan vendor because it seems not working in Laravel 9 neither.
I've tested the following libraries and they didn't run in Laravel 9:
L5 Swagger
laravel-apidoc-generator
Laravelista and Vendor
Can anyone help me?
Upgrading Laravel 6.14.0 to 7 for my laravel backend app
and reading this doc https://laravel.com/docs/7.x/upgrade#upgrade-7.0
I have errors with support of barryvdh/laravel-cors, as I got erorr in console:
Class 'Barryvdh\Cors\ServiceProvider' not found
If to comment 1 line In config/app.php :
// Barryvdh\Cors\ServiceProvider::class,
and reference in app/Http/Kernel.php
I passed console commands(like config cache).
But I got CORS errors in my vue/cli app.
I tried to search in net for Barryvdh\Cors
and seems here https://packagist.org/packages/barryvdh/laravel-cors there is support for laravel 7,
but if installation was changed?
Also I found this https://github.com/fruitcake/laravel-cors package.
Is it replacement of Barryvdh\Cors? Which steps have I to take to run my app as laravel 7?
Thanks!
Yes, Laravel 7 includes first-party support for configuring Cross-Origin Resource Sharing (CORS). It looks like you will have to add the fruitcake/laravel-cors dependency. here is the CORS Support upgrade information from the Laravel documentation.
Yes the vendor name has changed, you can find the upgrade guide here:
Upgrading from 0.x
When upgrading from 0.x versions, there are some breaking changes:
The vendor name has changed (see installation/usage)
Group middleware is no longer supported.
A new 'paths' property is used to enable/disable CORS on certain routes. This is empty by default!
The casing on the props in cors.php has changed from camelCase to snake_case, so if you already have a cors.php file you will
need to update the props in there to match the new casing.
You can find the installation / usage guide here.
PS:
Laravel 5.5 and onward support package auto-discovery so you don't have to add anything into config/app.php anymore.
i have installed the chat package:
https://github.com/dazzz1er/confer
Unfortunately i get an error when i try to publish it. Here is the error:
[Symfony\Component\Debug\Exception\FatalErrorException]
Call to undefined method Illuminate\Support\Facades\View::composer()
Thanks !
As correctly pointed out by #curious_coder confer is not compatible with Laravel 5.2 yet. Please keep an on the open Laravel 5.2 issue on Github and/or ask the author of this package for updates.
I am using Laravel 5.0.3 for one project few days ago. Now I create another project using the same version but I noticed the declaration (or whatever you call it) has changed from something like:
'Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode'
to
\Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode::class
and this is actually causing an FatalError. My idea is that this is something to do with the php version, but I don't want to update just yet.
What options do I have to sort this issue?
It's called class name resolution and a new feature that is implemented in PHP 5.5. The reason that you are getting that error is your PHP version of your PHP interpreter should be lower than PHP 5.5. Don't forget that Laravel 5.1 LTS package requires PHP 5.5.9 version minimum. You can keep your old configuration as 'Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode' instead of \Illuminate\Foundation\Http\Middleware\CheckForMaintenanceMode::class. But first, you should also downgrade your Laravel version from 5.1 to 5. Better and recommended is to upgrade your PHP version as PHP 5.4 will be soon deprecated.
I am using codeigniter 2.1.2 and I want to use scaffolding feature to add information to table. When I set this $route['scaffolding_trigger'] = 'scaffolding'; in routes.php and call it in controller $this->load->scaffolding('applicants'); I get the following Error:
Fatal error: Call to undefined method CI_Loader::scaffolding() in C:\xampp\htdocs\hmplatform\application\controllers\Applicant.php on line 6 So I am asking if I can find a library that contains scaffolding features because in this version I downloaded from GIT there is no scaffolding folder.
Scaffolding was depreciated in codeigniter. It isn't longer offered. The tutorials are outdated, so I'm guessing this is where you saw it?