Using Web Services in PHP5 to access the Java EE Application (1) _php tutorial

Source: Internet
Author: User
Tags wsdl
Many Web developers like PHP's rich functionality and ease of use, but sometimes they need access to the business logic existing in the Java EE application Server. This article will show you how to use a WEB service to access a Java EE application using a new SOAP extension in PHP 5, without leaving the PHP environment or learning a new programming model.
Introduction to PHP, Web services, and SOAP
This article describes how to access enterprise applications from a PHP script. You may be a PHP programmer who needs to write code for a departmental Web application to access the services provided by the company's headquarters as a Web service. You may be an experienced Java EE developer who wants to learn more about PHP and its applications. The example in this article is a run on IBM WebSphere? Enterprise JavaBean (EJB) on the application server, but this article does not discuss the deployment of the Web service. Its main goal is to describe how to use Web services from PHP, which can be applied to a variety of Web service implementations.
What is PHP?
Php:hypertext Preprocessor (Hyper-text preprocessor, PHP) is a popular server-side scripting language used to create dynamic WEB content. PHP Interpreter provides source code or compiled binaries for mainstream platforms, including most Linux? Version, Windows?, Mac OS X, and iSeries?.
There are indeed millions of WEB servers running PHP, most of which use PHP 4. PHP 5, introduced in July 2004, is gradually being adopted. PHP 5 has improved the object model, and the underlying memory management has been redesigned from a multi-threaded and performance perspective. However, there are a few changes that are not backwards compatible and are documented in the PHP manual.
What is WEB services technology?
WEB services refer to self-contained, modular applications where clients and services are loosely coupled. For more information about WEB services, you only need to understand the main technologies in this article:
SOAP (Simple Object Access Protocol) defines the messages that are passed between the client and the server. The message is in XML format. SOAP is independent of the platform, programming language, network, and Transport layer. This article discusses SOAP on HTTP.
WSDL (Web Service Description Language) is an XML-based language that describes a Web service, including the location, format, operations, parameters, and data types of the service.
UDDI (Unified description, Discovery, and integration) is implemented using APIs and UDDI Registry to provide methods for storing and retrieving information about Web services on the network.
This article includes some examples of SOAP messages and WSDL documents, but does not provide examples of UDDI.
The XMethods Web site is a useful Web services tool where you can find a list of publicly available Web services implemented on various server platforms. You can use the examples in this article to easily access the services selected from XMethods.

http://www.bkjia.com/PHPjc/631760.html www.bkjia.com true http://www.bkjia.com/PHPjc/631760.html techarticle Many Web developers like PHP's rich functionality and ease of use, but sometimes they need access to the business logic existing in the Java EE application Server. This article will pass some examples to illustrate ...

  • 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.