URL

Typeproperty
Dictionarywidget.browser
LibraryBrowser
Syntax
set the URL of <widget> to <pUrl>
get the URL of <widget>
Associationscom.livecode.widget.browser
Summary

The URL displayed by the browser.

Parameters
NameTypeDescription
pUrl

A string specifying a URL.

Example
-- Navigate to livecode.com by setting the url property,
-- keeping a copy of the previous URL
local tOldUrl
put the URL of widget "myBrowser" into tOldUrl
set the URL of widget "myBrowser" to "https://livecode.com"
RelatedProperty: htmlText
Description

The URL is the URL of the content be displayed in the browser.

Note: The URL must be a standards-compliant URL. In particular, file: URLs must be of the form file://<b>absolute path</b>, and the path should be URL-encoded. See RFC 1738, section 2.2.

Note: The URL reflects the currently displaying page in the browser, and will change when navigating to another page. Setting the htmlText will result in the URL being empty.

Note: Setting the URL won't necessarily cause resources to be reloaded unless URLs of the resources explicitly change. However, you can force the browser widget to reload a page using do "location.reload()" in widget "browser" after setting the url.

Note: Setting the URL to empty will clear the currently loaded page, resulting in a blank page being displayed and the URL and htmlText of the widget being empty.