Can anybody convert this code to php for me.. this is code is used to access a webservice but i only C# code they are not providing any documentation.

Thanks in advance

private CrmService CreateService()
        cs = new CrmService();

        string username = ConfigurationManager.AppSettings["Username"].ToString();
        string password = ConfigurationManager.AppSettings["Password"].ToString();
        string domain = ConfigurationManager.AppSettings["Domain"].ToString();
        string orgname = ConfigurationManager.AppSettings["Org"].ToString();
        string url = ConfigurationManager.AppSettings["CrmSdk.CrmServiceWsdl"].ToString();
        cs.Credentials = new NetworkCredential(username, password, domain);
       // cs.Credentials = CredentialCache.DefaultCredentials;
        cs.Url = url;
     //   OrganizationServiceProxy orgServiceImpersonate = new OrganizationServiceProxy(new Uri(p.orgUri), p.homeuri, p.credentials, p.deviceCredentials);
        CrmAuthenticationToken token = new CrmAuthenticationToken();
        token.OrganizationName = orgname;
        cs.CrmAuthenticationTokenValue = token;
        cs.PreAuthenticate = true;
        return cs;
3 Years
Discussion Span
Last Post by BogdanCov

I think this will be more difficult than it appears as there are a few calls to classes - which I assume would also have to be converted.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.