Difference between revisions of "StartDefaultBrowser"

From The Official Visionaire Studio: Adventure Game Engine Wiki
Line 1: Line 1:
<div class="toccolours mw-collapsible mw-collapsed tbl-ds">
+
==startDefaultBrowser==
<span class="bold">Command History</span>
 
<div class="mw-collapsible-content">
 
<div class="alt-bg">Available since v?</div>
 
</div></div>
 
  
 +
<div class="command-min-version-info">Available since: <span class="command-min-version">v3.0</span></div>
  
Allows you to open an url inside of your default internet browser!
+
<div class="command-doc">Open an url in user's default browser or in the steam overlay (if active).</div>
  
 
+
Lua Syntax:
Syntax:
+
<pre class="command-syntax">startDefaultBrowser(Url)</pre>
 +
===Arguments===
 +
====Url====
 +
:'''"string"''' - The url which should be opened
 +
===Flags===
 +
===Return Values===
 +
;status
 +
:True if browser was successfully launched, false otherwise.
 +
===Examples===
 +
Example 1: launch default browser & open included link, if browser is already running then open link in a new tab
 
<syntaxhighlight>
 
<syntaxhighlight>
startDefaultBrowser("url")
 
</syntaxhighlight>
 
 
 
Example:
 
<syntaxhighlight enclose="div">
 
-- launch default browser & open included link else if browser is already then open link in a new tab!
 
 
startDefaultBrowser("http://visionaire-studio.net")
 
startDefaultBrowser("http://visionaire-studio.net")
 
</syntaxhighlight>
 
</syntaxhighlight>
 
 
 
<span class="bold underline">Arguments</span>
 
 
<span class="bold">url</span>: "string" <br/>
 
The url to be opened inside of your default internet browser! (if default browser is already open; then the url will be opened in a new tab)
 
 
 
<span class="bold underline">Flags</span>
 
 
none
 
 
 
<span class="bold underline">Return</span>
 
 
<span class="bold">status</span> <br/>
 
True/false depending if the browser was successfully launched!
 
{{i18n|StartDefaultBrowser}}
 

Revision as of 17:12, 22 November 2013

startDefaultBrowser

Available since: v3.0
Open an url in user's default browser or in the steam overlay (if active).

Lua Syntax:

startDefaultBrowser(Url)

Arguments

Url

"string" - The url which should be opened

Flags

Return Values

status
True if browser was successfully launched, false otherwise.

Examples

Example 1: launch default browser & open included link, if browser is already running then open link in a new tab

startDefaultBrowser("http://visionaire-studio.net")