Forums / Developer / SOAP Webservice with eZ publish 4.0

SOAP Webservice with eZ publish 4.0

Author Message

Mickael Robin

Saturday 02 August 2008 11:28:05 am

Hi all,

I need to implement a webservice to interface eZ publish with SugarCRM.

More precisely I need to create a content in SugarCRM each time a visitor selects an item in my eZ publish website.
I would like to do it on-the-fly (i.e. avoiding cronjobs of an ETL on MySQL tables...), that is to say trough a webservice.

SugarCRM uses a SOAP API (based on NuSOAP) that would let me easily "import" the data strings, I only I knew how to "export" them with eZ ...!
The NuSOAP extension doesn't seem to work with eZ publish 4.0, but it seems that it is possible to use php curl to serve SOAP instructions.

What are the different possibilities?
=> inserting some code in eZ's "action.php" file to serve the XML file when a form is sent on eZ?
=> using a native SOAP server feature that I could not find in v4.0 doc?
=> maybe use the Shop module to trigger a SOAP event when an eZ content is put into cart?

I'm rather new at programing and I must confess I'm a little bit lost :-(

So thanks in advance for your insights !!!

Cheers,

MikRob

Kristof Coomans

Sunday 03 August 2008 2:10:22 am

Hi Mickael

It looks like there's a NuSOAP for PHP 5 project on Google Code: http://code.google.com/p/nusoap-for-php5/

I might take some time next week(s) to update my NuSOAP eZ Publish extension to use this updated library for PHP 5, and test it on eZ Publish 4. I'll keep you informed.

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Kristof Coomans

Sunday 03 August 2008 2:22:06 am

NuSOAP was moved to http://projects.ez.no/nusoap.

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Mickael Robin

Sunday 03 August 2008 2:50:48 am

Hi Kristof,
and thanks for planning to port your NuSOAP extension to php5 / eZ 4.0 .

eZ publish would be even better if it was easily connected / mashed up with other open source web applications !!!

I will be very pleased to test your extension (after learning about the whole SOAP thing...)

Mickael

Quynh Nguyen

Thursday 15 January 2009 1:04:50 am

Hi,

I can not find this download at project page. Is there any news?

Gunnar Velle

Monday 23 February 2009 1:36:56 pm

The nusoap library is updated so it supports php5. To upgrade the ez extension you just have to:
* Download the latest version of nusoap from http://sourceforge.net/projects/nusoap/
* Replace the files in ./extension/nusoap/classes with the new from the downloaded zip
* Add: require 'autoload.php'; to the start of nusoap.php in the ezroot (copied from ./extension/nusoap/install/nusoap.php)

Works as a charm on ez 4.0.0 on php 5.2.0
Good luck.

Gunnar

Kristof Coomans

Monday 23 February 2009 11:33:07 pm

Hi Gunnar

That project doesn't seem to contain any recent releases. Did you try from CVS then maybe? Thanks.

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Gaetano Giunta

Tuesday 24 February 2009 3:23:01 am

nusoap's latest commit was on 6/4/08, afaict.
The latest release is 0.7.3 - ignore the faulty changelogs and the sf.net project homepage only reporting version 0.7.1.
0.7.3 is php5 compatible and quite stable

Principal Consultant International Business
Member of the Community Project Board

Kristof Coomans

Tuesday 24 February 2009 4:45:18 am

I've been upgrading the extension today, with the latest revision from CVS. Works fine now on eZ Publish 4 (with some PHP 5 strict warnings though).

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Gunnar Velle

Friday 27 February 2009 5:09:24 am

Here's an idea: why not integrate nusoap with ez instead of the existing ez soap functionality? Then we could get a feature full soap framework which support for generating wsdls. It would simplify creating webservice interfaces to ez a great deal.

Gunnar

Alain Sahli

Wednesday 25 March 2009 12:45:03 pm

Hi !

Is there a way to add something in the .htaccess instead of creating a virtualhost ?

I tried this but it doesn't worked :

RewriteEngine On

RewriteRule /nusoap(.+) nusoap.php

RewriteRule content/treemenu/? index_treemenu.php
RewriteRule ^index_treemenu\.php - [L]

RewriteRule ^design/standard/images/favicon\.ico - [L]

RewriteRule !(\.(gif|jpe?g?|png|css|js|swf|html?)|nusoap|var(.+)storage.pdf(.+)\.pdf)$ index.php

DirectoryIndex index.php

I tried to access the page with www.mysite.com/nusoap but it doesn't worked...

http://www.wess.ch
eZ Publish Certified developer : http://auth.ez.no/certification/verify/272583

Gaetano Giunta

Friday 18 June 2010 6:09:53 am

btw, the ggwebservices extension supports calling soap services using the native php soap extension.

The new ezwebservicesapi extension allows calling ezp fetch functions and views as if they where webservices - no soap support yet, only xmlrpc and jsonrpc, but soap+wsdl is coming fast!

Principal Consultant International Business
Member of the Community Project Board

nehal shah

Thursday 23 June 2011 6:31:20 am

Hi Gunnar,

I have add nusoap extension, as above you have described.

But now tell me how can i use that webservice.

More precisely how can i use client page?

Gaetano Giunta

Thursday 23 June 2011 9:29:04 am

Did I mention that ggwebservices version 0.8 has wsdl support? ;-)

ciao

Gaetano

Principal Consultant International Business
Member of the Community Project Board