2

I developp a PHP application hosted on Heroku and which use the PHP Toolkit to interact with Force.com.

When I run the app on my computer, it works, data from Salesforce.com are loaded but when I push my app on the Heroku server, I get this error :

Class 'SoapClient' not found in /app/Soapclient/SfocePartnerClient.php on line 44

Line 44 :

class SforceSoapClient extends SoapClient {
  ...
}

What have I to configure on Heroku to fix the error please?

1
  • 2
    This is file composer.json : { "name": "developerforce/force.com-toolkit-for-php", "description": "A wrapper for the Force.com Web Services SOAP API", "license": "BSD-3-Clause", "autoload": { "classmap": [ "soapclient" ] }, "extra": { "branch-alias": { "dev-master": "1.0.x-dev" } }, "require": { "ext-soap": "*", "php": ">=5.4.0" } } Commented Jun 22, 2015 at 16:39

2 Answers 2

1

I fixed it by requiring "ext-soap" in composer.json:

{
    "require": {
        "ext-soap": "*",
        "php": ">=5.4.0"
    }
}

Run composer update to generate a composer.lock file, and push both files to Heroku, or manually deploy from Dropbox via https://dashboard.heroku.com/apps/your-app-name/deploy/dropbox

0

It didn't work because the soap extension wasn't correctly activated.

I had to create a case to the Heroku support.

Now, it works fine.

Aurélien

1
  • I'm having the same issue. Is it only fixable on their end? Commented Sep 4, 2017 at 15:01

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.