Support the ongoing development of Laravel.io →
posted 11 years ago
Packages

Hello, and thanks in advance for your help.

I want to use this curl package: https://packagist.org/packages/jyggen/curl

I've added it to my composer.json file

"require": {
		"laravel/framework": "4.1.*",
		"jyggen/curl": "4.0.*@dev"
	},

I've run composer update and it pulled the files into /vendor/jyggen

I've run composer dump-autoload and it added some lines to /vendor/composer/autoload_psr4.php

return array(
    'Monolog\\' => array($vendorDir . '/monolog/monolog/src/Monolog'),
    'Jyggen\\Curl\\Tests\\' => array($vendorDir . '/jyggen/curl/tests'),
    'Jyggen\\Curl\\' => array($vendorDir . '/jyggen/curl/src'),
);

Here is my controller

 <?php
require 'vendor/autoload.php';
use Jyggen\Curl;
class PlayController extends BaseController {


	public function index()
	{
	
		// Single URL
		var_dump(Curl::get('http://example.com/'));
	}
}

I get this error shown in the log

2014-05-21 10:37:03] production.ERROR: exception 'Symfony\Component\Debug\Exception\FatalErrorException' with message 'Class 'Jyggen\Curl' not found'

I'd value your assistance.

Thanks

Pete

Last updated 3 years ago.
0

@AndreasLutro solved this for me in the IRC. Turns out that the example on the vendors docs was wrong and I needed

use Jyggen\Curl\Curl;
Last updated 3 years ago.
0

Thank you Pete.

Last updated 3 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.