installed composer, defined my composer.json
{ "require": { "php": ">=5.2.0", "ext-curl": "*", "authorizenet/authorizenet": "1.8.6.2", "jms/serializer": "xsd2php-dev as 0.18.0" }, "require-dev": { "goetas/xsd2php": "2.*@dev", "goetas/xsd-reader": "2.*@dev" }, "repositories": [{ "type": "vcs", "url": "https://github.com/goetas/serializer.git" }] }
ran update and installed a billion things, when I test with the sample code I get :
Fatal error: Class 'JMS\Serializer\Annotation\Type' not found in /var/www/html/project/vendor/authorizenet/authorizenet/lib/net/authorize/util/SensitiveDataConfigType.php on line 6
The error occurs when I call:
$controller = new AnetController\CreateTransactionController($request);
after building my request as documented in the example. Any idea why this dependancy would fail to load? I hvae verified that the files do indeed exist. Thanks!
01-20-2016 05:16 PM
Hello @leotemp
It doesn't look like anyone has responded yet, but someone still may have feedback on what you're looking for. I'd recommend subscribing to this topic so that you'll be alerted via email if anyone else from the community is able to respond with any comments. To subscribe, click Topic Options at the top of this thread and then select Subscribe. You'll then receive an email once anyone replies to your post.
Thanks,
Richard
01-31-2016 09:38 AM
There are some files that aren't included in the SDK, classmap.php contains the list of files needed. Ones with the vendor dir seem to be the ones missing. I am downloading those files by finding them on google.
01-31-2016 05:06 PM
You need to run composer in the folder to pull in the missing libraries into the vendor folder.
06-11-2016 07:24 AM
This is a long shot, but worth a try. I ran into this same issue, and the problem was git. I had added some "log" entries into my .gitignore file, and this was causing my code to work locally, but when I moved it to a different computer or to a server, it wouldn't work. You may want to check this. Otherwise I suggest removing all composer.json and then doing a composer update, then adding them back, and composer update again.
06-23-2016 07:49 AM