{"id":1495,"date":"2012-11-19T11:51:06","date_gmt":"2012-11-19T06:21:06","guid":{"rendered":"http:\/\/live-42gears-site.pantheonsite.io\/blog\/?p=1495"},"modified":"2018-12-12T06:32:10","modified_gmt":"2018-12-12T06:32:10","slug":"surefox-javascript-apis","status":"publish","type":"post","link":"https:\/\/www.42gears.com\/de\/blog\/surefox-javascript-apis\/","title":{"rendered":"SureFox Javascript APIs"},"content":{"rendered":"<p>SureFox for Android now comes with built-in set of Javascript APIs. Use them in a customized SureFox toolbar or\u00a0embed in your web application to\u00a0perform\u00a0variety\u00a0of actions such as navigating through pages or to launch an app directly from SureFox.<\/p>\n<p>The APIs are written as <strong>window.surefox.&lt;API_Name&gt;<br \/>\n<\/strong><br \/>\nFollowing is a comprehensive list of SureFox APIs:<\/p>\n<ul>\n<li><strong>getVersion():<\/strong>\u00a0Gets SureFox Version<\/li>\n<\/ul>\n<div>\n<pre>                              window.surefox.getVersion();<\/pre>\n<\/div>\n<ul>\n<li><strong>getAndroidVersion()<\/strong>: Gets Device android version<\/li>\n<\/ul>\n<div>\n<pre>                              window.surefox.getAndroidVersion();<\/pre>\n<\/div>\n<ul>\n<li>\u00a0<strong>getDeviceModel():<\/strong>\u00a0Gets device model<\/li>\n<\/ul>\n<div>\n<pre>                              window.surefox.getDeviceModel();<\/pre>\n<\/div>\n<ul>\n<li><strong>forceIdleTimeout():<\/strong>\u00a0Forces idle timeout<\/li>\n<\/ul>\n<div>\n<pre>                              window.surefox.forceIdleTimeout();<\/pre>\n<\/div>\n<ul>\n<li><strong>autoMediaPlayEnabled():<\/strong>\u00a0Gets whether media playback enabled in surefox<\/li>\n<\/ul>\n<div>\n<pre>                              window.surefox.autoMediaPlayEnabled();<\/pre>\n<\/div>\n<ul>\n<li><strong>isAppInstalled(&#8222;packageName&#8220;):\u00a0<\/strong>Gets whether application with packagename is installed on device<\/li>\n<\/ul>\n<div>\n<pre>                              window.surefox.isAppInstalled('com.android.contacts');<\/pre>\n<\/div>\n<ul>\n<li><strong>setOrientation(integervalue):<\/strong>\u00a0Sets orientation based on value 0-6 (0 -Auto,1-Landscape,2-Portrait,3-Reverse Landscape,4-Reverse Portrait,5 &#8211; Auto Landscape, 6-Auto Portrait)<\/li>\n<\/ul>\n<div>\n<pre>                               window.surefox.setOrientation(5);<\/pre>\n<\/div>\n<ul>\n<li><strong>getURL():<\/strong>\u00a0Gets url of current tab<\/li>\n<\/ul>\n<div>\n<pre>                               window.surefox.getURL();<\/pre>\n<\/div>\n<ul>\n<li><strong>exit():<\/strong> Not applicable when SureFox is in Kiosk Mode<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.exit();<\/pre>\n<\/div>\n<ul>\n<li><strong>clearCache():<\/strong>\u00a0Clears surefox cache<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.clearCache();<\/pre>\n<\/div>\n<ul>\n<li><strong>clearOfflineData():<\/strong>\u00a0Clears offline data of surefox<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.clearOfflineData();<\/pre>\n<\/div>\n<ul>\n<li><strong>setIdleTimeoutForCurrentPage(intergerValue):<\/strong>\u00a0Sets idle timeout to specific value for current page<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.setIdleTimeoutForCurrentPage(60);<\/pre>\n<\/div>\n<ul>\n<li><strong>resetIdleTimeout():\u00a0<\/strong>Resets idle timeout<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.resetIdleTimeout();<\/pre>\n<\/div>\n<ul>\n<li><strong>getIdleTimeout():<\/strong>\u00a0Gets current idle timeout time<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.getIdleTimeout();<\/pre>\n<\/div>\n<ul>\n<li><strong>launch(packageName,restartFlag):<\/strong>\u00a0Launches specified application and restarts if restartFlag is true<\/li>\n<\/ul>\n<div>\n<pre>                                launch(com.android.contacts,true);<\/pre>\n<\/div>\n<ul>\n<li><strong>hardWareAcceleration(intValue):<\/strong>\u00a0Sets hardware acceleration to specified value 0- None,1-Software,2-Hardware<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.hardWareAcceleration(0);<\/pre>\n<\/div>\n<ul>\n<li><strong>closeCurrentTab():<\/strong>\u00a0Closes currently opened tab<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.closeCurrentTab();<\/pre>\n<\/div>\n<ul>\n<li><strong>closeAlltabs():<\/strong>\u00a0Closes all opened tabs<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.closeAlltabs();<span style=\"font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 13px; line-height: 19px;\">\u00a0<\/span><\/pre>\n<\/div>\n<ul>\n<li><strong>load(URL):<\/strong>\u00a0Loads the URL in the active screen of SureFox. URL is passed as a parameter to the API<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.load('http:\/\/www.google.com');<\/pre>\n<ul>\n<li><strong>\u00a0openInNewTab(URL):<\/strong>\u00a0Loads the URL in a new tab of SureFox.\u00a0URL is passed as a parameter to the API<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.openInNewTab('http:\/\/www.google.com');<\/pre>\n<ul>\n<li><strong>back():<\/strong>\u00a0Navigate to the previous page in SureFox<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.back();<\/pre>\n<ul>\n<li><strong>forward():<\/strong>\u00a0Navigate to the next page in SureFox<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.forward();<\/pre>\n<ul>\n<li><strong>home():<\/strong>\u00a0Loads SureFox home page<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.home();<\/pre>\n<ul>\n<li><strong>refresh():<\/strong>\u00a0Refreshes current web page<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.refresh();<\/pre>\n<ul>\n<li><strong>stop():<\/strong>\u00a0Stops any ongoing loading activity in SureFox<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.stop();<\/pre>\n<ul>\n<li><strong>launch(packagename):<\/strong>\u00a0Launches the application from SureFox. Only the package name of the application needs to be passed as a parameter to the API.<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.launch('com.android.contacts');<\/pre>\n<ul>\n<li><strong>launch(action,category,packagename,classname):<\/strong>\u00a0Use this to launch a particular activity of an application from SureFox.\u00a0The action, category, package name and class name of the application need to be passed as parameters to the API.<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.launch('android.intent.action.MAIN', 'android.intent.category.LAUNCHER', 'com.android.contacts', 'com.android.contacts.activities.PeopleActivity');<\/pre>\n<div style=\"text-align: center;\">\n<ul>\n<li style=\"text-align: left;\"><strong>launch(action,category,packagename,classname,URL):<\/strong>\u00a0Launches a specific activity of an application and navigate to a specific webpage.<\/li>\n<\/ul>\n<pre>window.surefox.launch('android.intent.action.VIEW','android.intent.category.LAUNCHER','com.android.chrome','com.google.android.apps.chrome.Main,'http:\/\/www.42gears.com')<\/pre>\n<\/div>\n<div>\n<ul>\n<li><strong>getIMEI():<\/strong>\u00a0Returns the IMEI number of the phone device<\/li>\n<\/ul>\n<div>\n<pre>                                window.surefox.getIMEI();<\/pre>\n<\/div>\n<div style=\"text-align: left;\">\n<ul>\n<li><strong>getWifiMAC():<\/strong>\u00a0Returns the WiFi MAC Address of the device<\/li>\n<\/ul>\n<div style=\"text-align: center;\">\n<pre>window.surefox.getWifiMAC();<\/pre>\n<div>\n<ul>\n<li style=\"text-align: left;\"><strong>getBluetoothMAC():<\/strong>\u00a0Returns the Bluetooth MAC Address of the device<\/li>\n<\/ul>\n<div>\n<pre>window.surefox.getBluetoothMAC();<\/pre>\n<\/div>\n<ul>\n<li style=\"text-align: left;\"><strong>getGUID():<\/strong>\u00a0Returns the GUID of the device<\/li>\n<\/ul>\n<pre>window.surefox.getGUID();<\/pre>\n<ul>\n<li style=\"text-align: left;\"><strong>launchFile(&#8218;file_path):<\/strong>\u00a0Launches the file from SureFox. Complete file path needs to be passed as a parameter to the API.<\/li>\n<\/ul>\n<pre>window.surefox.launchFile('\/mnt\/sdcard\/help.pdf);<\/pre>\n<ul>\n<li style=\"text-align: left;\"><strong>killApp(\u2018<wbr \/>packageName\u2019):<\/strong>\u00a0Kills \/Stops running applications on the device.<\/li>\n<\/ul>\n<pre>window.surefox.killApp(\u2018<wbr \/>packageName\u2019);<\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<hr \/>\n<p style=\"text-align: left;\">You can also use SureFox APIs to get and display battery status and perform actions based on the battery level. Following are the list of SureFox battery APIs:<\/p>\n<ul>\n<li><strong>battery().level():<\/strong>\u00a0Returns the current battery level<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.battery().level()<\/pre>\n<ul>\n<li><strong>battery().charging():<\/strong>\u00a0Returns &#8218;true&#8216; if battery is charging else returns a &#8218;false&#8216;<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.battery().charging()<\/pre>\n<div style=\"text-align: left;\">\n<ul>\n<li><strong>battery().addEventListener(&#8222;levelchange&#8220;, &#8222;&lt;user-defined-function&gt;&#8220;):<\/strong> Used to add an event listener for battery level which can be used to call any function of your choice<\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.battery().addEventListener(\"levelchange\", \"setLevel\");<\/pre>\n<ul>\n<li><strong>battery().addEventListener(&#8222;chargingchange&#8220;, &#8222;<strong>&lt;user-defined-function&gt;&#8220;<\/strong>):<\/strong><\/li>\n<\/ul>\n<pre style=\"text-align: center;\">window.surefox.battery().addEventListener(\"chargingchange\", \"setStatus\");<\/pre>\n<div>\n<div><\/div>\n<\/div>\n<div><strong style=\"font-size: 13px; line-height: 19px;\">Sample HTML page for displaying use of SureFox APIs:<\/strong><\/div>\n<div><\/div>\n<div id=\"attachment_1517\" style=\"width: 710px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/2111.png\"><img decoding=\"async\" aria-describedby=\"caption-attachment-1517\" class=\"size-full wp-image-1517\" title=\"SureFox Javascript API Demo page\" src=\"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png\" alt=\"SureFox Javascript API Demo page\" width=\"700\" height=\"438\" \/><\/a><p id=\"caption-attachment-1517\" class=\"wp-caption-text\">SureFox Javascript API Demo page<\/p><\/div>\n<p><strong>HTML Code<\/strong> for demo page:<\/p>\n<\/div>\n<div style=\"font-size: 12px; width: 710px; height: 318px; overflow: auto; border: 1px dashed #000000;\">\n<p>&lt;html&gt;<br \/>\n&lt;head&gt;<br \/>\n&lt;title&gt;SureFox Javascript APIs&lt;\/title&gt;<br \/>\n&lt;script type=&#8220;text\/javascript&#8220;&gt;<br \/>\nfunction setLevel(value) {<br \/>\ndocument.querySelector(&#8218;#level&#8216;).textContent = &#8222;Battery Level = &#8220; + value*100+&#8220;%&#8220;;<br \/>\n}<br \/>\nfunction setStatus(value) {<br \/>\ndocument.querySelector(&#8218;#status&#8216;).textContent = &#8222;Charging: &#8220; + window.surefox.battery().charging();<br \/>\n}<br \/>\nfunction getdeviceInfo() {<br \/>\ndocument.querySelector(&#8218;#IMEI&#8216;).textContent = &#8222;IMEI: &#8220; + window.surefox.getIMEI();<br \/>\ndocument.querySelector(&#8218;#WiFiMAC&#8216;).textContent = &#8222;WiFi MAC: &#8220; + window.surefox.getWifiMAC();<br \/>\ndocument.querySelector(&#8218;#BTMAC&#8216;).textContent = &#8222;Bluetooth MAC: &#8220; + window.surefox.getBluetoothMAC();<br \/>\ndocument.querySelector(&#8218;#GUID&#8216;).textContent = &#8222;GUID: &#8220; + window.surefox.getGUID();<br \/>\n}<br \/>\nfunction init() {<br \/>\nsetLevel(window.surefox.battery().level());<br \/>\nsetStatus(window.surefox.battery().charging());<br \/>\nwindow.surefox.battery().addEventListener(&#8222;levelchange&#8220;, &#8222;setLevel&#8220;);<br \/>\nwindow.surefox.battery().addEventListener(&#8222;chargingchange&#8220;, &#8222;setStatus&#8220;);<br \/>\ngetdeviceInfo();<br \/>\n}<br \/>\n&lt;\/script&gt;<br \/>\n&lt;style&gt;<br \/>\nbody<br \/>\n{<br \/>\nmargin: 0px;<br \/>\n}<br \/>\n.bar<br \/>\n{<br \/>\npadding: 5px 15px;<br \/>\nbackground-color: #87D2FF;<br \/>\nborder-radius: 5px;<br \/>\ncolor: #ffffff;<br \/>\nfont-weight: bold;<br \/>\ntext-shadow: 0 0 1px #525252;<br \/>\n}<br \/>\n&lt;\/style&gt;<br \/>\n&lt;\/head&gt;<\/p>\n<p>&lt;body onload=&#8220;javascript:init()&#8220;&gt;<\/p>\n<p>&lt;div id=&#8220;container&#8220; style=&#8220;background-color: #cccccc; height: 62px; position:relative;&#8220;&gt;<br \/>\n&lt;div style=&#8220;float:right; margin: 5px 5px 0px 0px; background-color: rgba(255, 255, 255, 0.62); padding: 5px 10px; height: 68%; &#8222;&gt;<br \/>\n&lt;!&#8211;&lt;b&gt;&lt;u&gt;Real Time Battery Status:&lt;\/u&gt;&lt;\/b&gt;&#8211;&gt;<br \/>\n&lt;div id=&#8220;status&#8220; style=&#8220;background-image: url(.\/charging.png); background-repeat: no-repeat; margin: 0 0 0 -6px; padding: 0 0 0 40px; background-position: left; display: inline-block;&#8220;&gt;(charging state unknown)&lt;\/div&gt;<br \/>\n&lt;div id=&#8220;level&#8220; style=&#8220;background-image: url(.\/battery.png); background-repeat: no-repeat; margin: 0 0 0 -6px; padding: 0 0 0 40px; background-position: left; display: block;&#8220;&gt;(battery level unknown)&lt;\/div&gt;<br \/>\n&lt;\/div&gt;<br \/>\n&lt;div style=&#8220;position:absolute; top:20%; left:0; width:100%;&#8220;&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.home();&#8220;&gt;<br \/>\n&lt;button class=&#8220;bar&#8220;&gt;Home&lt;\/button&gt;<br \/>\n&lt;\/span&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.back();&#8220;&gt;<br \/>\n&lt;button class=&#8220;bar&#8220;&gt;Back&lt;\/button&gt;<br \/>\n&lt;\/span&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.forward();&#8220;&gt;<br \/>\n&lt;button class=&#8220;bar&#8220;&gt;Forward&lt;\/button&gt;<br \/>\n&lt;\/span&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.refresh();&#8220;&gt;<br \/>\n&lt;button class=&#8220;bar&#8220;&gt;Refresh&lt;\/button&gt;<br \/>\n&lt;\/span&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.stop();&#8220;&gt;<br \/>\n&lt;button class=&#8220;bar&#8220;&gt;Stop&lt;\/button&gt;<br \/>\n&lt;\/span&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.launch(&#8218;com.android.calendar&#8216;);&#8220;&gt;<br \/>\n&lt;button class=&#8220;bar&#8220;&gt;Calendar&lt;\/button&gt;<br \/>\n&lt;\/span&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.launch(&#8218;android.intent.action.MAIN&#8216;, &#8218;android.intent.category.LAUNCHER&#8216;, &#8218;com.android.vending&#8216;, &#8218;com.android.vending.AssetBrowserActivity&#8216;);&#8220;&gt;<br \/>\n&lt;button class=&#8220;bar&#8220;&gt;Google Play&lt;\/button&gt;<br \/>\n&lt;\/span&gt;<br \/>\n&lt;\/div&gt;<br \/>\n&lt;\/div&gt;<br \/>\n&lt;br \/&gt;<br \/>\n&lt;b&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.load(&#8218;https:\/\/www.42gears.com&#8216;);&#8220;&gt;Click to visit 42Gears&lt;\/span&gt;<br \/>\n&lt;br \/&gt;<br \/>\n&lt;br \/&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.openInNewTab(&#8218;http:\/\/www.google.com&#8216;);&#8220;&gt;Click to launch Google(Open in new tab)&lt;\/span&gt;<br \/>\n&lt;br \/&gt;<br \/>\n&lt;br \/&gt;<br \/>\n&lt;span onclick=&#8220;window.surefox.launchFile(&#8218;\/mnt\/sdcard\/SureFox.settings&#8216;);&#8220;&gt;Click to launch document&lt;\/span&gt;<br \/>\n&lt;br \/&gt;<br \/>\n&lt;br \/&gt;<br \/>\n&lt;\/b&gt;<br \/>\n&lt;div id=&#8220;IMEI&#8220; style=&#8220;margin: 0 0 0 0px; padding: 0 0 0 0px; background-position: left; display: block;&#8220;&gt;(IMEI unknown)&lt;\/div&gt;<br \/>\n&lt;div id=&#8220;WiFiMAC&#8220; style=&#8220;margin: 0 0 0 0px; padding: 0 0 0 0px; background-position: left; display: block;&#8220;&gt;(WiFi MAC address unknown)&lt;\/div&gt;<br \/>\n&lt;div id=&#8220;BTMAC&#8220; style=&#8220;margin: 0 0 0 0px; padding: 0 0 0 0px; background-position: left; display: block;&#8220;&gt;(Bluetooth MAC address unknown)&lt;\/div&gt;<br \/>\n&lt;div id=&#8220;GUID&#8220; style=&#8220;margin: 0 0 0 0px; padding: 0 0 0 0px; background-position: left; display: block;&#8220;&gt;(GUID unknown)&lt;\/div&gt;<br \/>\n&lt;\/body&gt;<br \/>\n&lt;\/html&gt;<\/p>\n<p>&nbsp;<\/p>\n<\/div>\n<p style=\"text-align: left;\">To know more about SureFox, <a title=\"Click here to know more about SureFox\" href=\"https:\/\/www.42gears.com\/surefox\/surefoxandroid.html\" target=\"_blank\" rel=\"noopener noreferrer\">click here<\/a><\/p>\n<blockquote><p>To learn more on how to secure and manage Android, iOS and Windows Mobile\/CE devices efficiently, visit us at\u00a0<a title=\"Click Here\" href=\"https:\/\/www.42gears.com\/\" target=\"_blank\" rel=\"noopener noreferrer\">www.42gears.com<\/a><\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>SureFox for Android now comes with built-in set of Javascript APIs. Use them in a customized SureFox toolbar or\u00a0embed in your web application to\u00a0perform\u00a0variety\u00a0of actions such as navigating through pages or to launch an app directly from SureFox. The APIs are written as window.surefox.&lt;API_Name&gt; Following is a comprehensive list of SureFox APIs: getVersion():\u00a0Gets SureFox Version&hellip;<\/p>\n","protected":false},"author":7,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[8,16],"tags":[22,33,15],"class_list":["post-1495","post","type-post","status-publish","format-standard","hentry","category-general","category-surefox","tag-android","tag-kiosk","tag-surefox"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v24.6 (Yoast SEO v24.6) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>SureFox Javascript APIs - 42Gears Mobility Systems<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/\" \/>\n<meta property=\"og:locale\" content=\"de_DE\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SureFox Javascript APIs\" \/>\n<meta property=\"og:description\" content=\"SureFox for Android now comes with built-in set of Javascript APIs. Use them in a customized SureFox toolbar or\u00a0embed in your web application to\u00a0perform\u00a0variety\u00a0of actions such as navigating through pages or to launch an app directly from SureFox. The APIs are written as window.surefox.&lt;API_Name&gt; Following is a comprehensive list of SureFox APIs: getVersion():\u00a0Gets SureFox Version&hellip;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/\" \/>\n<meta property=\"og:site_name\" content=\"42Gears Mobility Systems\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/42gears\" \/>\n<meta property=\"article:published_time\" content=\"2012-11-19T06:21:06+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2018-12-12T06:32:10+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png\" \/>\n<meta name=\"author\" content=\"42Gears Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@42Gears\" \/>\n<meta name=\"twitter:site\" content=\"@42Gears\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"42Gears Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"7 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/\"},\"author\":{\"name\":\"42Gears Team\",\"@id\":\"https:\/\/www.42gears.com\/#\/schema\/person\/28a14f2c32de4a7903ac672579a88a2d\"},\"headline\":\"SureFox Javascript APIs\",\"datePublished\":\"2012-11-19T06:21:06+00:00\",\"dateModified\":\"2018-12-12T06:32:10+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/\"},\"wordCount\":1138,\"commentCount\":2,\"publisher\":{\"@id\":\"https:\/\/www.42gears.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png\",\"keywords\":[\"Android\",\"kiosk\",\"SureFox\"],\"articleSection\":[\"General\",\"SureFox\"],\"inLanguage\":\"de-DE\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/\",\"url\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/\",\"name\":\"SureFox Javascript APIs - 42Gears Mobility Systems\",\"isPartOf\":{\"@id\":\"https:\/\/www.42gears.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png\",\"datePublished\":\"2012-11-19T06:21:06+00:00\",\"dateModified\":\"2018-12-12T06:32:10+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#breadcrumb\"},\"inLanguage\":\"de-DE\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"de-DE\",\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage\",\"url\":\"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png\",\"contentUrl\":\"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.42gears.com\/de\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"SureFox Javascript APIs\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.42gears.com\/#website\",\"url\":\"https:\/\/www.42gears.com\/\",\"name\":\"42Gears Mobility Systems\",\"description\":\"Mobile Device Management (MDM), Mobile Security &amp; Mobile Device Lockdown\",\"publisher\":{\"@id\":\"https:\/\/www.42gears.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.42gears.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"de-DE\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.42gears.com\/#organization\",\"name\":\"MDM - 42Gears\",\"url\":\"https:\/\/www.42gears.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"de-DE\",\"@id\":\"https:\/\/www.42gears.com\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.42gears.com\/wp-content\/uploads\/2018\/12\/Featured-Image-42Gears-logo.png\",\"contentUrl\":\"https:\/\/www.42gears.com\/wp-content\/uploads\/2018\/12\/Featured-Image-42Gears-logo.png\",\"width\":499,\"height\":330,\"caption\":\"MDM - 42Gears\"},\"image\":{\"@id\":\"https:\/\/www.42gears.com\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/42gears\",\"https:\/\/x.com\/42Gears\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.42gears.com\/#\/schema\/person\/28a14f2c32de4a7903ac672579a88a2d\",\"name\":\"42Gears Team\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"de-DE\",\"@id\":\"https:\/\/www.42gears.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/7d257fb658a429b8607872336eac3833a8314ca3ca67d72c90ceeddc7700c42e?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/7d257fb658a429b8607872336eac3833a8314ca3ca67d72c90ceeddc7700c42e?s=96&d=mm&r=g\",\"caption\":\"42Gears Team\"}}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"SureFox Javascript APIs - 42Gears Mobility Systems","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/","og_locale":"de_DE","og_type":"article","og_title":"SureFox Javascript APIs","og_description":"SureFox for Android now comes with built-in set of Javascript APIs. Use them in a customized SureFox toolbar or\u00a0embed in your web application to\u00a0perform\u00a0variety\u00a0of actions such as navigating through pages or to launch an app directly from SureFox. The APIs are written as window.surefox.&lt;API_Name&gt; Following is a comprehensive list of SureFox APIs: getVersion():\u00a0Gets SureFox Version&hellip;","og_url":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/","og_site_name":"42Gears Mobility Systems","article_publisher":"https:\/\/www.facebook.com\/42gears","article_published_time":"2012-11-19T06:21:06+00:00","article_modified_time":"2018-12-12T06:32:10+00:00","og_image":[{"url":"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png","type":"","width":"","height":""}],"author":"42Gears Team","twitter_card":"summary_large_image","twitter_creator":"@42Gears","twitter_site":"@42Gears","twitter_misc":{"Written by":"42Gears Team","Est. reading time":"7 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#article","isPartOf":{"@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/"},"author":{"name":"42Gears Team","@id":"https:\/\/www.42gears.com\/#\/schema\/person\/28a14f2c32de4a7903ac672579a88a2d"},"headline":"SureFox Javascript APIs","datePublished":"2012-11-19T06:21:06+00:00","dateModified":"2018-12-12T06:32:10+00:00","mainEntityOfPage":{"@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/"},"wordCount":1138,"commentCount":2,"publisher":{"@id":"https:\/\/www.42gears.com\/#organization"},"image":{"@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage"},"thumbnailUrl":"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png","keywords":["Android","kiosk","SureFox"],"articleSection":["General","SureFox"],"inLanguage":"de-DE","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/","url":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/","name":"SureFox Javascript APIs - 42Gears Mobility Systems","isPartOf":{"@id":"https:\/\/www.42gears.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage"},"image":{"@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage"},"thumbnailUrl":"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png","datePublished":"2012-11-19T06:21:06+00:00","dateModified":"2018-12-12T06:32:10+00:00","breadcrumb":{"@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#breadcrumb"},"inLanguage":"de-DE","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/"]}]},{"@type":"ImageObject","inLanguage":"de-DE","@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#primaryimage","url":"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png","contentUrl":"https:\/\/www.42gears.com\/wp-content\/uploads\/2012\/11\/211.png"},{"@type":"BreadcrumbList","@id":"https:\/\/www.42gears.com\/fr\/blog\/surefox-javascript-apis\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.42gears.com\/de\/"},{"@type":"ListItem","position":2,"name":"SureFox Javascript APIs"}]},{"@type":"WebSite","@id":"https:\/\/www.42gears.com\/#website","url":"https:\/\/www.42gears.com\/","name":"42Gears Mobility Systems","description":"Mobile Device Management (MDM), Mobile Security &amp; Mobile Device Lockdown","publisher":{"@id":"https:\/\/www.42gears.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.42gears.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"de-DE"},{"@type":"Organization","@id":"https:\/\/www.42gears.com\/#organization","name":"MDM - 42Gears","url":"https:\/\/www.42gears.com\/","logo":{"@type":"ImageObject","inLanguage":"de-DE","@id":"https:\/\/www.42gears.com\/#\/schema\/logo\/image\/","url":"https:\/\/www.42gears.com\/wp-content\/uploads\/2018\/12\/Featured-Image-42Gears-logo.png","contentUrl":"https:\/\/www.42gears.com\/wp-content\/uploads\/2018\/12\/Featured-Image-42Gears-logo.png","width":499,"height":330,"caption":"MDM - 42Gears"},"image":{"@id":"https:\/\/www.42gears.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/42gears","https:\/\/x.com\/42Gears"]},{"@type":"Person","@id":"https:\/\/www.42gears.com\/#\/schema\/person\/28a14f2c32de4a7903ac672579a88a2d","name":"42Gears Team","image":{"@type":"ImageObject","inLanguage":"de-DE","@id":"https:\/\/www.42gears.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/7d257fb658a429b8607872336eac3833a8314ca3ca67d72c90ceeddc7700c42e?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/7d257fb658a429b8607872336eac3833a8314ca3ca67d72c90ceeddc7700c42e?s=96&d=mm&r=g","caption":"42Gears Team"}}]}},"author_meta":{"ID":"7","user_nicename":"42gears","user_email":"42gears@gmail.com","user_registered":"2015-07-15 04:55:37","display_name":"42Gears Team","first_name":"42Gears","last_name":"Team"},"_links":{"self":[{"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/posts\/1495","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/comments?post=1495"}],"version-history":[{"count":12,"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/posts\/1495\/revisions"}],"predecessor-version":[{"id":28727,"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/posts\/1495\/revisions\/28727"}],"wp:attachment":[{"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/media?parent=1495"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/categories?post=1495"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.42gears.com\/de\/wp-json\/wp\/v2\/tags?post=1495"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}