Question

I am using ZendOAuth to authenticate with an OAuth authentication. I have installed the package and all it dependencies using composer. But when I try to use this code, it can't find the Zend classes.

I use the following example code to test if the OAuth is working:

$consumer = new Zend_Oauth_Consumer($this->options);
$token = $consumer->getRequestToken();
echo $token;

When I execute the code I get an error telling me that the class Zend_Oauth_Consumer could not be found.

I am sure my composer packages are correctly loaded because all other packages work fine.

Can someone tell me if I am forgetting something? Do I need an extra include or use?

Was it helpful?

Solution

There is no such class in the library. I think you mean:

$consumer = new \ZendOAuth\Consumer($this->options);
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top