You need to sign in to do that
Don't have an account?
piyush parmar
salesfroce connection using PHP toolkit,, its urgent
Hi all..
I am able to connect salesforce using PHP toolkit in sandbox.
But when i am try to connect production org i am getting this type of error.
Fatal error: Uncaught SoapFault exception: [INVALID_LOGIN] INVALID_LOGIN: Invalid username, password, security token; or user locked out. in /home/sites/public_html/sales/soapclient/SforceBaseClient.php:155 Stack trace: #0 [internal function]: SoapClient->__call('login', Array) #1 /home/sites//public_html/sales/soapclient/SforceBaseClient.php(155): SoapClient->login(Array) #2 /home/sites/public_html/sales/Upload.php(33): SforceBaseClient->login('username.', 'password+token') #3 {main} thrown in /home/sites/public_html/sales/soapclient/SforceBaseClient.php on line 155
here my username , password and security tokan is correct ,
than why i am getting this type of error ??
please reply me its urgent ..
Thank you
piyush
one more addition,
Please make sure your SOAP EndPoint url contains https://test.salesforce.com/ not https://login.salesforce.com/
Thanks,
Bala
All Answers
Simple. Because your IP address hasn't been authorized. Either use your Salesforce Token or authorize your IP address under Setup -> Security -> Network Access.
Oh, you do say that your security token is correct. I'm would have assumed that the security token from the sandbox and the production org would be the same, but you may want to check that. The only other option is that your user account could have API access disabled. Please check that setting as well. It's under the Profile Settings for that paticular user.
one more addition,
Please make sure your SOAP EndPoint url contains https://test.salesforce.com/ not https://login.salesforce.com/
Thanks,
Bala
b-Force, I now read his note again and I think that's exactly what the issue is. Good job on that.
You have forget some basic steps. Follow the following link and connect your rest api.............
require_once ('soapclient/SforcePartnerClient.php');
require_once ('soapclient/SforceEnterpriseClient.php');
define("USERNAME", "user@gmail.com");
define("PASSWORD", "pass@123");
define("SECURITY_TOKEN", "kahjsjgdgvs4657wkheku6sd");
$mySforceConnection = new SforcePartnerClient();
$mySforceConnection->createConnection("soapclient/partner.wsdl.xml");
If you have query then please let me know ?