- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sandbox - is composer necessary to run?
Hi, I have not installed composer because the hello world says you don't necessarily have to - but I have not gotten it to run. I followed the instructions here:
http://developer.authorize.net/hello_world/
The SDK is installed, plus charge-credit-card.php
My errors are as follows:
Warning: require(vendor\autoload.php) [function.require]: failed to open stream: No such file or directory in /home/starticr/public_html/webwork/authorize-sandbox/charge-credit-card.php on line 2
Warning: require(vendor\autoload.php) [function.require]: failed to open stream: No such file or directory in /home/starticr/public_html/webwork/authorize-sandbox/charge-credit-card.php on line 2
Fatal error: require() [function.require]: Failed opening required 'vendor\autoload.php' (include_path='.:/opt/alt/php53/usr/share/pear:/opt/alt/php53/usr/share/php') in/home/starticr/public_html/webwork/authorize-sandbox/charge-credit-card.php on line 2
I know it's looking for autoload.php - which is in the root directory of the test link. But if I change the path from vendor\autoload.php to just autoload.php, it gives me different warnings/errors and still doesn't run.
I believe the problem is that Composer is not installed. But is there a way to do this without Composer? My next step will be to install Composer.
I copied the code directly from http://developer.authorize.net/hello_world/ - I replaced setName and setTransactionKey values with the values that were given to me from the Sandbox login.
Here is my test link:
http://startwebservices.com/webwork/authorize-sandbox/charge-credit-card.php
Can anyone give me direction here? Do I just need to install composer? I would really appreciate some help, thanks!
09-19-2016 10:52 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Also if Composer is not installed, where does the vendor folder come from?
09-19-2016 10:57 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello @mcmstart
If you are using our SDK, then yes Composer is required. Your other option is to use our API and handle your own XML/JSON request and responses.
Richard
09-19-2016 11:05 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the response Richard. I've been following the steps to install composer to my sandbox test directory, but it won't install the components.
composer.phar is installed in a directory called authorize-sandbox, and all of the Authorize.net sandbox files are also in this directory, including composer.json. I ran this line:
php /home/starticr/public_html/webwork/authorize-sandbox/composer.phar install
but it tells me:
Composer could not find a composer.json file in /home/starticr
It's apparently looking in the wrong place for the composer.json file.
Do you know what I'm doing wrong here?
09-28-2016 02:27 PM - edited 09-28-2016 02:29 PM

