The module structure that composes browser/server structure.
As shown in the above picture, use POWERBUILDER6. 0 The various internet-based applications developed by PowerBuilder6.0 are implemented by using Distributed application technology and powerscripts programming techniques, which is equivalent to writing server applications in distributed applications. For example, the use of powerscripts language Environment, Data window technology. Its production process and working principles are:
1. Establish and configure a WEB server. PowerBuilder's 32-bit multiple-threaded Personal Web server website 1.1, based on the WindowsNT 3.51 version and win 95/98 platform, was brought in by the O ' Reilly Company. This Web server provides a complete Web service creation, management environment, and security mechanism.
2. Establish an executable program (WEB.PB) on the WEB server. The main function of the WEB.PB (Pbcgi60.exe) program is to invoke the preset handlers in the PowerBuilder application server, including analyzing the user functions in the execution user object, feedback the HTML control flow and generating the interpreter inserts.
WEB.PB is an essential part of developing web-based applications that are itself a gateway application on the Web. The tool provides access from the Web server to the PowerBuilder application server, allowing users to perform near-complete manipulation of the database over the Web, both on the Internet and under the intranet. At the same time, it is possible to create HTML documents dynamically through WEB.PB. The WEB.PB program is a bridge between the Web server and the PowerBuilder application server. Using WEB.PB to build Web applications has the following advantages:
A. Support for CGI, ISAPI, NSAPI, MSAPI and many other gateway program interfaces.
B. Supports references to data windows in PowerBuilder.
C. Easy to migrate previously written PowerBuilder applications into a Web environment.
D. Easy to create HTML files embedded in PowerBuilder applications, the application server in the running environment, will be based on user needs, dynamic generation of HTML syntax, the release of fully dynamic information.
E. Support for database connections. The databases that PowerBuilder can connect to are accessible to browser users, making Web services and database services fully integrated through PowerBuilder 6.0.
3. Establish PowerBuilder Application Server. PowerBuilder application servers are mainly composed of class library programs for activating Powerbuilder6.0 business applications. When you create the PowerBuilder application server shown above, you must refer to the Powerbuilder6.0 Web Class library, which defines five custom class user objects that encapsulate a variety of entities such as functions, structures, and instances needed to create HTML syntax and transaction management. Can be used to create HTML syntax, manage the status of client browser connections, and so on. The PowerBuilder 6.0 application server is equivalent to a client application in a distributed application to make call requests to PowerBuilder6.0 business applications. The execution method is to start the predefined business handlers in the PowerBuilder application server when the Powerbuilder6.0 application server hears the WEB.PB request.
For example, when a user browses a page using a Web browser (ie or Netscape) on the browser side, the Web server can automatically activate the WEB.PB application by embedding a or
element in an HTML page. The active Web server first invokes the PowerBuilder6.0 WEB.PB class program as a client application in PowerBuilder distributed applications, establishing a connection with the PowerBuilder 6.0 application Server, It then invokes the various business functions defined in the PowerBuilder6.0 application server, that is, user functions encapsulated in user-defined objects, including data processing such as database access and file processing.
4. Establish PowerBuilder business applications. In a user-defined object, create a user-defined function. Functional requirements are based on browser end user needs, business data processing, the processing results in HTML page format, feedback to the WEB.PB program, often used in personnel management, financial management, information processing and system management and other business work. The PowerBuilder business application has two styles of inserts (Plug_ins) and embedded HTML files. The Plug-ins (insert) method is divided into window plug-ins and DataWindow plug-ins two kinds.
Window Plug-ins inserts a business program by embedding and displaying the window object of the child type in PowerBuilder6.0 on an HTML page, placing the Data window (DataWindow), tree Browsing (TreeView), A rich variety of control types, such as tab pages, enrich the presentation of HTML pages. When the client browses the page in a browser, the Web server unloads the PSR file or PBD file to the customer, the client browser receives the PSR file and the PBD file, embeds the child window object in the Web page, and if the Window object is embedded, the function defined on the window can also be used in the browser environment , such as the function of database manipulation defined on the window, the browser client can directly connect to manipulate the database. Plug-ins play the role of embedding PowerBuilder6.0 objects into the page, the Data window has a rich display style, users are more welcome to the browser "Powerbuilder Child class Data Window" data representation.
Window ActiveX is used similar to Window plug-ins, which embeds and displays the child type PowerBuilder object in the HTML page. This component can be used interactively with vbscripts and javascripts in HTML.
The simple embedding of HTML files is a popular programming trend, that is, not inserting a product at all, the client simply installs the regular web browser, it can realize the real "thin" browser/client/server structure system.
In summary, the Powerbuilder6.0 application server returns the execution results of the business handler to the Web server in HTML format. The Web server then publishes HTML to the user, and the client browser receives the results on the browser.