2

I want to install guzzle https://github.com/guzzle/guzzle

I read the reference, but I'm confused this section :

enter image description here

From that tutorial, asking for require composer autoloader. So seems needed to add require 'vendor/autoload.php'; Where I add the script?

I using laravel 5.6

1 Answer 1

5

You don't have to do anything if you are going to install guzzle in Laravel. The example above is for core php actually. Laravel will automatically do it for you.

Just run composer require guzzlehttp/guzzle in your terminal. (of course in the directory where your laravel project actually is.)
And add use GuzzleHttp\Client; at the top of the file you will be calling guzzle from.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.