WebBrowser (open)

Utility class to communicate with HTTP servers

Syntax

LOADLIB "wh::internet/webbrowser.whlib";

OBJECTTYPE WebBrowser

Constructor

Variables

  • BOOLEAN debug

    log everything we do

  • FUNCTION PTR OnError

    Called when an error occurs. Signature: MACRO onerror(STRING lastmessage)

  • FUNCTION PTR onrequest

    Called before every request, can be used to modify the request Signature: FUNCTION onrequest(RECORD data)

    • url URI
    • method HTTP method
    • headers List of headers
    • body Body Return: modified record
  • BOOLEAN printnavigation

    print navigation actions. testfw uses this so we don't need to print every flaky navigation action

  • MACRO PTR ARRAY pvt_traffichooks

    List of macro ptrs that will be called for every request Signature: MACRO hook(BOOLEAN beforerequest, STRING method, STRING url, INTEGER transactionid, RECORD data);

  • STRING ARRAY ssloptions

    List of SSL options to use

    • "SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION": Allow legacy insecure renegotiation between OpenSSL and unpatched clients or servers.

Properties

Functions