|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #53293 WSDL error when schemaLocation includes port number
Submitted: 2010-11-11 04:35 UTC Modified: 2015-06-12 17:34 UTC
Avg. Score:4.8 ± 0.6
Reproduced:11 of 13 (84.6%)
Same Version:7 (63.6%)
Same OS:4 (36.4%)
From: dpholden at gmail dot com Assigned:
Status: Open Package: SOAP related
PHP Version: 5.3SVN-2010-11-11 (snap) OS: Windows 7
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
Solve the problem:
11 + 39 = ?
Subscribe to this entry?

 [2010-11-11 04:35 UTC] dpholden at gmail dot com
When trying to parse a WSDL document using SoapClient and the WSDL document contains <imports> or <includes> and the schemaLocation includes a port number (ie. :80) it fails and produces a Soap Fault.

Test script:
$client = new SoapClient('', array('trace' => 1));


Expected result:
A list of functions related to the WSDL.

Actual result:
Error: SOAP-ERROR: Parsing Schema: can't import schema from ''


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2010-11-11 04:37 UTC] dpholden at gmail dot com
<xs:import namespace="" schemaLocation=""/>

The above is where in the WSDL that it appears to fail parsing
 [2010-11-25 22:27 UTC]
-Status: Open +Status: Feedback
 [2010-11-25 22:27 UTC]
Seems to work fine here.

The only error I am seeing is:

Fatal error: Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing Schema: 
unresolved element 'ref' attribute
 [2010-11-26 03:52 UTC] dpholden at gmail dot com
-Status: Feedback +Status: Open
 [2010-11-26 03:52 UTC] dpholden at gmail dot com
I've just tried this again, using the same code I've posted here and only that and it is still giving me the same error.

iliaa, what version of PHP are you using and which environment?

I am using WAMP server, PHP Version 5.3.0

Soap Client 	enabled
Soap Server 	enabled

Directive	         Local Value	Master Value
soap.wsdl_cache	              1	              1
soap.wsdl_cache_dir	     /tmp	    /tmp
soap.wsdl_cache_enabled	      1	              1
soap.wsdl_cache_limit	      5	              5
soap.wsdl_cache_ttl	     86400	    86400

And in case it is relevant my SimpleXML version.

Simplexml support	enabled
Revision 	        $Revision: $
Schema support 	        enabled
 [2010-11-26 03:54 UTC] dpholden at gmail dot com
Ok I've just run the same script on a Linux server

PHP Version 5.1.6
Apache/2.2.3 (Red Hat) 

SimpleXML revisions differ

Revision 	$Revision: $ 

Revision 	$Revision: $ 

On the linux version, I am getting the same result as you iliaa:

Fatal error:  Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing Schema: unresolved element 'ref' attribute
 [2015-06-12 17:34 UTC]
-Package: XML related +Package: SOAP related
 [2022-12-29 09:25 UTC] sheyda dot babi5161 at gmail dot com
ok  for the information keep sharing such informative post keep suggesting such post. (
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sat Sep 23 15:01:24 2023 UTC