www.webdeveloper.com
Results 1 to 4 of 4

Thread: I get gateway time-out when I pass wsdl from a file to the SOAPClient?

  1. #1
    Join Date
    Jul 2012
    Posts
    11

    I get gateway time-out when I pass wsdl from a file to the SOAPClient?

    Hi to every one

    I am facing a strange problem with the web service that I am trying to integrate.

    The wsdl for the web service is available online on this https://www.quiddiportal.com/quiddiservice.asmx?WSDL link and also I have stored the wsdl in a file WS.wsdl in my workspace.

    The strange is that when I am passing the wsdl to SOAPClient using the URI (online & local) everything works fine. So when I put

    PHP Code:
    $client = new SoapClient("http://localhost/myProject/WSDL.wsdl");
    or 
    $client = new SoapClient("https://www.quiddiportal.com/quiddiservice.asmx?WSDL"); 
    everything works fine.

    But when I put only the name of the wsdl file.

    PHP Code:
    $client = new SoapClient("WSDL.wsdl"); 
    I get an "Gateway Time-out" error from the line where I call a function of the web service. I use Netbeans and I run the projects in my console. Although if I call the same code that gives me this error from a browser then everything works fine.

    Do you have any idea why this is happening?

  2. #2
    Join Date
    Aug 2004
    Location
    Ankh-Morpork
    Posts
    19,247
    I'm no SOAP guru by any means, but the manual suggest the first argument to the constructor is a URI, so I'd guess you'll have to use the 'localhost' URI option for local testing.
    "Please give us a simple answer, so that we don't have to think, because if we think, we might find answers that don't fit the way we want the world to be."
    ~ Terry Pratchett in Nation

    eBookworm.us

  3. #3
    Join Date
    Jul 2012
    Posts
    11
    Quote Originally Posted by NogDog View Post
    I'm no SOAP guru by any means, but the manual suggest the first argument to the constructor is a URI, so I'd guess you'll have to use the 'localhost' URI option for local testing.
    Ok NogDog, I understand what you are saying. But shouldn't be working with the relative path too?
    The weird thing is that the error is not coming from the line
    Code:
    $client = new SoapClient("WSDL.wsdl");
    but from the
    Code:
    $response = $client->PostApplicationResult
    .

    When I debug the code it seems that the SOAPClient object is instantiated properly.

    What is the gateway time-out actually?

  4. #4
    Join Date
    Aug 2004
    Location
    Ankh-Morpork
    Posts
    19,247
    My guess is that it's trying to access what it interprets as "http://WSDL.wsdl" and times out when it cannot resolve that domain-- but that is just a guess.
    "Please give us a simple answer, so that we don't have to think, because if we think, we might find answers that don't fit the way we want the world to be."
    ~ Terry Pratchett in Nation

    eBookworm.us

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles