# Links

Click the following links to install menus popped by long pressing the bookmark button (with star as icon):
VPN

Wait for network msg

Certificate info

Web fullscreen

Long pressing the bookmark button in uweb browser will popup menus defined in file "default.link". The file format is as follows:
[Menu name]:[url][space][javascript code]

in which space and later parts are optional. url and later parts support "%u","%s" etc.. The javascript code will be executed after url is fully loaded.

url supports all standard scheme (http(s):,javascript: etc.) and uweb internal schemes ( ':' as second character in the url ) and special links that begins with ':'.

uweb browser will handle local file urls (file:///) specially for some file types：

- .js file(same as long pressing hypertext to execute js file): If the ".js" file begins with "//", then uweb browser will load the site following "//" and execute the following js code.

default.gesture and default.button have the exactly same file format. ".gesture" files define gestures while ".button" define bottom toolbar button pressing actions from the last button to the first.

proxy config:
httpproxy::010[proxy host]:[port]
socks5::011[socks host]:[port]
noproxy::010:

### special links beginning with ':'

- :0000
  Extend cookie expiracy to 70 years, may be denied by server.

- :0003
  Toggle fullscreen mode

- :0004
  Rotate the screen

- :001[fileurl]
  Scan the fileurl and add it to media storage

- :002[url]
  Show the secure cookie

- :010[proxy host]:[port]
  Config http proxy, ":010:" to disable any proxy.

- :011[socks host]:[port]
  Socks proxy

### "i:" internal links:

- i:0m[bookmarklet index|prefix?postfix|c[cssFlag]]:[url]
  Visiting url and execute the uweb browser internal bookmarklet that keeps valid for all urls under the path of [url].

[bookmarklet index] must have two/three digits. The first two digits are used as index of bootmarklet. For example, "00" as the first local bookmarklet; "01" as the first remote script; then "02" as the second local bookmarklet, ... The third digit is uplevel, 1 to make bookmarklet valid for parent path of [url].

- c[cssFlag]: For example, "c12" will apply the third and fourth global CSS (12=2^2+2^3).

- All other cases will be treated as [prefix?postfix], the real visited url is "[prefix]+[url]+[?postfix]".

- i:15[string]
  Set address bar text to be [string].

- i:16[mimetype]:[Action Name]:[App Name]:[Activity Name]
  Use third party app as input

- i:18[extended mimetype]:[range]:[url]
  Read partial data from url.
  <range>: the format is same as related http header, such as "500-1000,-300".
  <extended mimetype>: standard mimetype or mimetype followed by ".<filename>". In the later case, the file in uweb configuration folder will be appended to the fetched data.

- i:19[string]
  Append [string] to the address bar text.

- i:1b
  Show web certificate.

- i:1c
  Wait to receive url from the network and open the url.

- i:1c1
  Wait to receive url from the network and open the url (not showing ip)

- i:1d<action>:<type>:<Category>:
  Launch app for specific <action>.

- i:50[path]:[string]
  Save [string] as file

- i:51[path]:[url]
  Save [url] to ".autoc" file.

- i:52[path]:[url]
  Save bookmark.

- i:53[path]:[string]
  Save notes.

- i:54[path]:[url]
  Save as search engine.

- i:55[path]:[url]
  Save as link.

- i:56[string]
  Use [string] as user input on web page.

- i:57[jscode]
  execute [jscode], even when js is disabled for the web page.

- i:58[url]
  Save to the desktop.

- i:5a[filename]
  Receive content from network to the file.

- i:5b[string]
  Copy [string] to the clipboard.

- i:5c[url]
  Change auto page turning internal url to be [url].

- i:5d[file url]
  Open the file url compatible to other browsers.

- i:5e[string]
  TTS

- i:5f[videourl]
  play video fullscreen. if videourl is empty, then make following requestFullscreen() work.

- i:5g[videourl]
  play video in external player

- i:5h[url]
  force html for url

- i:5i[url]
  Use the existing tab for the url to jump to a different anchor.

- i:5j[string]
  if [string] is file url, then send the file/folder to network, otherwise send [string] to network.

- i:60[path]:[url]
  If existing local file, then open it or visit the [url].

- i:62[path]:[js code]
  Evaluate the [js code] and save the returned string to file.

- i:63[bookmarklet index]:[url]
  Visiting url and execute the bookmarklet. Only uweb predefined local bookmarlets are allowed.

- i:70[url]:[auto page turning url]
  Visiting [url], but use the second url as auto paging url.