function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
KevlangdoKevlangdo 

Enterprise PHP call Invalid Session ID

"INVALID_SESSION_ID: Invalid Session ID found in SessionHeader: Illegal Session"

I tested some code with the partner wsdl and I was able create an Contact with no issues

I am trying into create > 4000 sales records using Enterprise wsdl.
I am using stdClass
I checked my session id at start of session and at create
 
public function __construct(){
        require_once('SforceEnterpriseClient.php');
        require_once('SforceHeaderOptions.php');
        require_once('userAuth.php');
       // session_start();
        $this->testSforceConnection = new SforceEnterpriseClient();
        $this->testSoapClient = $this->testSforceConnection ->createConnection($this->wsdl);
        $this->testSFDClogin = $this->testSforceConnection ->login($this->USERNAME, $this->PASSWORD.$this->Token);


        $_SESSION['location']=$this->testSforceConnection ->getLocation();
        $_SESSION['sessionId']=$this->testSforceConnection ->getSessionId();
        $_SESSION['wsdl']=$this->wsdl;

    }



But I am getting the invalid sesison id. I need to use enterprise because I am inserting into custom object.
I users has Sys Admin access

What to do?