Module Browser

The Browser module provides a way to display markup in your web browser. On the Windows platform, the default installed browser will be started up to display the page. On UNIX platforms, WebL tries to communicate with an already running copy of Netscape. Note that to implement this functionality, WebL has to write the markup to a temporary file in the specified character encoding.

On the Windows platform only, module Browser also provides rudimentary support for inquiring and controlling a running copy of a Netscape browser with Dynamic Data Exchange ( DDE). Specifically it is possible to detect what web page is being viewed in the browser, and to request Netscape to navigate to a specific URL. Both the support for viewing markup and the DDE functionality is bundled in a Windows platform-specific DLL called weblwin32.dll. The readme.txt file that is part of the WebL distribution contains instructions how to install this DLL on a Windows machine.

 

Module Browser

Function

Description

GetCurrentPage(): object

(Windows only)
Returns information about the currently viewed page in a running copy of Netscape. The object returned has string fields url and title that specifies the viewed URL and title of the viewed page respectively.

GotoURL(url: string): nil

(Windows only)
Sends a request to a running copy of Netscape to navigate to this url.

ShowPage(s: string): nil

Displays the markup contained in s in a web browser (uses the default locale for externalizing the string).

ShowPage(s: string, charset: string): nil

As above, but ensuring that the string is externalized in the indicated character set. Values for charset might be "iso-8859-1", "Unicode", "UTF8", etc.


Up Previous Next