Section 15.0. Introduction


15.0. Introduction

This chapter covers building web services. If you're unfamiliar with the fundamental concepts of web services, including REST, SOAP, and XML-RPC, jump back a chapter and read through Chapter 14. It provides the building blocks for the web services servers described here.

Recipe 15.1 covers building a REST method. With a REST server, you accept an HTTP request, process the incoming data, and reply, usually with XML.

From there, the chapter moves to SOAP. Recipes Recipe 15.2 and 15.3 show how to serve a SOAP method with and without input arguments.

Recipe 15.4 breaks the bad news that PHP cannot automatically generate WSDL files from PHP classes, while Recipe 15.5 shows how to throw SOAP faults.

SOAP headers are the topic of the next two recipes. First, in Recipe 15.6, you learn how to process a SOAP header. Then, Recipe 15.7 shows how to generate a SOAP header.

The SOAP portion concludes with a discussion on how to combine authentication with SOAP in Recipe 15.8.

The chapter concludes with a Recipe 15.9, a recipe on serving XML-RPC requests.




PHP Cookbook, 2nd Edition
PHP Cookbook: Solutions and Examples for PHP Programmers
ISBN: 0596101015
EAN: 2147483647
Year: 2006
Pages: 445

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net