Constructing remote services using XML technology in PHP (1) _php tutorial

Source: Internet
Author: User
Tags knowledge base
The future of the web will be a service-centric WEB,XML_RPC standard making it very easy to write and apply services. This article introduces the XML_RPC Standard and its PHP implementation, and demonstrates how to develop XML_RPC services and client programs in PHP with examples.

One, service-type web

From the simple approach adopted by the content provider to the future vision of UDDI (Universal description,discovery and integration), the industry already has a lot of notes and comments about the "serviced Web". For the start-up phase of the web, it is just a distribution center of documents, providing only a few browsable information. As the web develops, running services on the web is increasingly appealing. In the future, the web will become a carrier for customers and other enterprises to provide convenient services. Collaboration between business-to-business and business-to-business models can be seen as a service web.

A very important question is, what services are available on the Web? The web can provide a lot of services, some of which are now in use, and some services will appear in the near future. To illustrate the problem, a small subset of the services available through the Web are listed below:

A topic-oriented vertical search engine.
A knowledge base for users to find information.
Users can ask questions of the expert system.
Banking services.
News and information Publishing services.
Digital payment-related services.
Graphics processing services.
Health and health services.

So what's the right way for businesses and organizations to deliver services through the Web? This is a very important question. Today, some services provide HTML interfaces that provide services in the form of documents, but what is hidden behind the service interface? In the race to occupy the Web, Web browsers are not alone, and devices like mobile phones, handheld devices, and microwaves want to access the Web, query databases, transform data, extract information, and so on. To implement a truly serviced web, there should be another layer beneath the presentation layer (HTML).

Second, XML_RPC standard

XML is perhaps the most important standard in nearly 10 years, and the XML Glossary (vocabulary) provides the cornerstone for an enterprise to construct a service environment. Building a serviced web is necessary to learn the XML_RPC standard, not only because XML_RPC is useful for putting services on the web, but also because XML_RPC is a well-formed, easy-to-use standard. The standard of service delivery is extremely important for business-to-service services, and companies that work together to comply with standards can gain rapid growth with services from other companies. It cannot be imagined that a truly serviced web can be built on a variety of private service standards, and that services must have a standard to follow.

XML_RPC is a standard for distributed processing on the Internet. RPC is the abbreviation for Remote procedure call, a remote call mechanism that invokes procedures that may reside on other machines and may be written in other languages. Remote procedure calls are an important pillar of distributed computing. For example, in a distributed computing environment, where we can find and take advantage of the process of performing addition and subtraction operations on other machines, the process of performing the addition may be written in APL, run on the rs6000 machine, and the process of performing the subtraction operation may be written in C and run on UNIX. Other developers who want to use this distributed calculator can also use them, or he can choose a better calculator.

In RPC, the process (procedure) is the most important component, and the server provides the process for the client to invoke. The procedure can receive parameters and return results. XML_RPC uses HTTP as the protocol carrier to implement RPC mechanisms by sending and receiving XML vocabularies for data. The XML_RPC server receives the XML_RPC request and returns a XML_RPC answer, XML_RPC the client sends a XML_RPC request and receives a XML_RPC response. Servers and customers must process responses and requests as required by the XML_RPC standard.

1

http://www.bkjia.com/PHPjc/446691.html www.bkjia.com true http://www.bkjia.com/PHPjc/446691.html techarticle the future of the web will be a service-centric WEB,XML_RPC standard making it very easy to write and apply services. This paper introduces the XML_RPC standard and its implementation of PHP, and demonstrates how to ...

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.