Ad
Laravel Salesforce Require_once?
I got a problem.I made a new class for my controller, in this class I do that to connect to salesforce
require_once ('salesforce/soapclient/SforceEnterpriseClient.php');
but I still have a problem.
(1/1) FatalErrorException Class 'App\Services\SforceEnterpriseClient' not found
Ad
Answer
Laravel is not meant to use require_once, which is a standard PHP expression. Use a Composer package such as this: https://packagist.org/packages/phpforce/soap-client
If you do need to require a specific file, add it into your app directory, maybe under a new Integrations folder and give it a believe namespace of App\Integrations
. Then, in your controller, use App\Integrations\SforceEnterpriseClient;
Ad
source: stackoverflow.com
Related Questions
- → "failed to open stream" error when executing "migrate:make"
- → October CMS Plugin Routes.php not registering
- → OctoberCMS Migrate Table
- → OctoberCMS Rain User plugin not working or redirecting
- → October CMS Custom Mail Layout
- → October CMS - How to correctly route
- → October CMS create a multi select Form field
- → October CMS - Conditionally Load a Different Page
- → How to disable assets combining on development in OctoberCMS
- → October CMS - Radio Button Ajax Click Twice in a Row Causes Content to disappear
- → OctoberCms component: How to display all ID(items) instead of sorting only one ID?
- → In OctoberCMS how do you find the hint path?
- → How to register middlewares in OctoberCMS plugin?
Ad