TFrameBrowser Demo
Internet Component Suite - ICS V8

Demo Quick Facts -- Please Read

- For online browsing, enter the URL. For example:

  `www.pbear.com/` or `github.com/BerndGabriel/HtmlViewer`

- To view a local html or image file, use the File menu or enter `file:///` followed by the filename.
- This document is a resource contained within this program. To view this document again in the future, select Help|Demo Information from the menu or enter `res:///page0.htm`.
- To compile this demo program for your own needs, see Compiling the Demo.
- The latest HtmlViewer is available at: https://github.com/BerndGabriel/HtmlViewer
- ICS v8 and the SSL DLL files may be downloaded from http://wiki.overbyte.be/wiki/index.php/ICS_Download

Overview

The HTML Component set consists of the THtmlViewer, TFrameViewer, and TFrameBrowser components. All three are HTML document display components:

| THtmlViewer | The basic component. THtmlViewer displays single (non-frame) documents. It forms the basis for the other two components.
| TFrameViewer | Displays both Frame and single HTML documents. TFrameViewer is oriented more for local disk file use.
| TFrameBrowser | Also displays Frame and single HTML documents. However, TFrameBrower is oriented toward Internet style protocols and URL usage. Additional code and/or components are generally required to use TFrameBrowser.

Demo Program

The FrameBrowserId demo program illustrates how the TFrameBrowser component might be used in a complete application.

The demo program supports the following protocols:

| http | Internet online protocol
|  | https | Internet online SSL protocol (optional)

file Internet local file protocol
res Specail protocol to read HTML documents from an application's resources

Protocol Details

When initially loading an HTML document, the full URL including the protocol should be used. From that point on, TFrameBrowser is capable of adding the protocol and path to partial URLs found in the document.

The http, https, and file protocols supported by the demo program are standard. URLs using these protocols are in the form:

      http://www.pbear.com/index.html
      file:///c|/thtml4/framedem.htm

The res protocol may be used to access HTML documents and their images stored in a program's resources. URLs with the res protocol have the form:

      res:///helpinfo.html

The res protocol supports document extensions of `HTM, HTML, GIF, JPG, JPEG, PNG, BMP, CSS,` and `TXT`. See Adding HTML Documents to an Application's Resources for information on how to add HTML resources to an application.

Additional special protocols may be easily added by the programmer. Protocols might be defined for reading encrypted files or reading HTML from a database, for instance. See Adding Your Own Protocols.