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
Peter KempPeter Kemp 

Connecting to Sandbox and Live accounts with the partner WSDL

I've written and tested a salesforce to MySQL backup tool in php (https://sourceforge.net/projects/unforced/).  I did all the testing in the sandbox and would now like to switch over to our live org.  I've changed the username and password and even refreshed the partner wsdl though it won't connect to the live org with security token or without.  Any idea what I'm doing wrong?  I get the following error:

 

 

SoapFault Object
(
[message:protected] => INVALID_LOGIN: Invalid username or password or locked out.
[string:private] =>
[code:protected] => 0
[file:protected] => C:\xampp\htdocs\test\salesforcebu\includes\soapclient\SforceBaseClient.php
[line:protected] => 155
[trace:private] => Array

 EDIT:

 

I notice that the WSDL I am getting from the live org says api version 15.0whilst the toolkit is only 13.0.  Also I have changed line

 

 

<soap:address location="https://www.salesforce.com/services/Soap/u/15.0"/>

 

 To point to the cs2 or live depnding on which login I use.  for the test accounts it doesn't matter, but for the live account, neither works.
I have checked my user rights on the live server and I am a System Administrator with API enabled == True.  Is there a setting on the live org that I am missing?

 

Thanks

 

Pete

 

Message Edited by Peter Kemp on 04-27-2009 04:14 AM
Message Edited by Peter Kemp on 04-27-2009 07:31 AM
SuperfellSuperfell
PHP aggressively caches WSDLs, so even though you've changed the WSDL, i suspect that your requests are still going to sandbox. Search this forum for more details, you can disable the caching though a php.ini setting.
Peter KempPeter Kemp

Hi Simon,

thanks for the quick response. The top of my code currently looks like this and I still have the error described:

 

 

ini_set("soap.wsdl_cache_enabled", "0"); require_once ('./includes/soapclient/SforcePartnerClient.php'); require_once ('./includes/adodb/adodb.inc.php');

 

Is there anything else I can do about the soap caching?

 

Peter KempPeter Kemp

Ah, it looks like there was one of the include files that didn't have the caching statement, apparently you need it on every page that uses it.

 

Thanks

 

Pete