To register for an Internet.com membership to receive newsletters and white papers, use the Register button ABOVE.
To participate in the message forums BELOW, click here
PHPBuilder.com  
 

 

Go Back   PHPBuilder.com > PHP Help > Upgrading PHP

Upgrading PHP Issues concerning PHP version upgrades and future releases

Reply
 
Thread Tools Rate Thread Display Modes
Old 08-12-2004, 06:34 PM   #1
bubblenut
Copyleft Commie
 
bubblenut's Avatar
 
Join Date: Oct 2003
Location: London
Posts: 2,370
SOAP with headers ...

... unless you can think of a better way.
Background:
I'm trying to build a dynamic webservices framework (you can check out the beginings here) which runs on handler classes which extend the ProtocolHadler abstract class. The problem I am having is with building a SOAPHandler class (well actually not the class itself but anyway).
This is what I have so far for the class.
PHP Code:
require_once 'ProtocolHandler.class.php';

class
SOAPHandler extends ProtocolHandler {
    
private $cmd;

    function
__construct($module) {
        
parent::loadModule($module);
    }

    function
__call($method, $arguments) {
        
$this->cmd=$method;
        return
parent::executeFunction($this->cmd, $arguments);
    }
}
What I'm really having difficulty with is how to implement it.
PHP Code:
$server = new SoapServer(null, array('uri'=>'http://som.url.com/somthing'));
$server->setClass('SOAPHandler', $module);
$server->handle();
Which is all well and good (so long as __call works as I expect it to but that's for later) except for the fact that $module needs to be retrieved from the client. I'm thinking that the obvious place to put this kind of data would be in a SOAP-HEADER but I can't seem to figure out how to add SOAP headers with SoapClient or read them with SoapServer.

I did think that I could read $GLOBALS['HTTP_RAW_POST_DATA'] with DOM and get the header like that but I'm thinking that would be really really hard. Besides, it wouldn't address the SoapClient issue.

If anyone can think of another way of tackling the problem, without SOAP headers, then please let me know.

Thanks
Bubble
__________________
If at first it doesn't work, slap it with a dirty hack.

Moral of the week: Never let a moral of the week go on for more than a week, it's even sillier than feeding the admins.

My Blog
bubblenut is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 11:03 AM.






Acceptable Use Policy

internet.comMediabistrojusttechjobs.comGraphics.com

WebMediaBrands Corporate Info


Advertise | Newsletters | Feedback | Submit News

Legal Notices | Licensing | Permissions | Privacy Policy


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.