Http://oreilly.com/catalog/9780596001193
Because of the project's external API needs, today read Dave winer's programming Web Services with XML-RPC, he is the initiator of the XML-RPC (one ).
First, let's talk about this book: It's best to see the translation version (I don't know if there are any) If I haven't passed cet6. The sentence structure is complicated and the vocabulary is strange, after six levels of brute-force attacks, I should still be able to cope with the past; the book's content is good, <foreword> talked about the Origin and Development of xml_rpc, <preface> just look at it, <Chapter 1. introduction> I have no idea. The most amazing chapter for me does not belong to <Chapter 2. the XML-PRC protocol>, from data types, request format, to response format are wonderful, but also can finish reading the results of the chapter. The subsequent chapters are from Java,
Perl, PHP, and ASP are used for detailed analysis. Unfortunately, PHP is only half a page.
Then I read the phprpc http://phprpc.org/zh_cn/on the internet, and made a demo and found it quite useful.
The client uses JS,CodeAs follows:
RPC
PHP is used on the server. The Code is as follows:
<? PHP require_once ("phprpc/phprpc_server.php"); $ Server = new phprpc_server (); function hi ($ name) {return 'Hello '. $ name ;}$ server-> Add ("sha1"); $ server-> Add ("hi"); $ server-> Start ();?>
In general, implementing RPC in dynamic languages is quite convenient.