<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Hide address bar on map/page load in mobile device? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-address-bar-on-map-page-load-in-mobile-device/m-p/314450#M28921</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm trying to figure out how to automatically hide the address bar when the map is finished loading.&amp;nbsp; This can easily be accomplished on iPhones by creating a shortcut on the home screen by adding this to the head:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; [HTML]&amp;lt;meta name="apple-mobile-web-app-capable" content="yes" /&amp;gt;[/HTML]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;But... since I'm trying to make the user experience as consistent as possible (and not force users to create shortcuts) I need to hide the address bar in either case (and not use up valuable screen real estate).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Everything I've found so far relies on "scrolling" to the top of the page or setting the height of the page body to a few pixels larger than what is really needed.&amp;nbsp; In a map app, scrolling doesn't apply and the map element is loaded as height:100%... setting the height to 101% or higher doesn't work either (believe me, I've tried).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here's what I've found so far (none of which seem to work in mobile Safari on an iPhone):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;1) Adding this meta link in the head although the user-scalable=yes is contrary to the Esri JavaScript samples (where they list user-scalable=0):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [HTML]&amp;lt;meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=yes;" /&amp;gt;[/HTML]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;2) Using straight JS to "scroll" to the top of the page&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; function page_Load() { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setTimeout(function() { window.scrollTo(0, 1); }, 100); &amp;nbsp;&amp;nbsp;&amp;nbsp; } &amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;3) Wrapping the body in jQuery and using that toolkit to do the same thing as #2:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $('body').scrollTop(1); &amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So far, none of these things are working... does anyone know how to successfully hide the address bar automatically (while the device is oriented in portrait)?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 12 Apr 2013 19:05:12 GMT</pubDate>
    <dc:creator>NickO_Day</dc:creator>
    <dc:date>2013-04-12T19:05:12Z</dc:date>
    <item>
      <title>Hide address bar on map/page load in mobile device?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-address-bar-on-map-page-load-in-mobile-device/m-p/314450#M28921</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm trying to figure out how to automatically hide the address bar when the map is finished loading.&amp;nbsp; This can easily be accomplished on iPhones by creating a shortcut on the home screen by adding this to the head:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; [HTML]&amp;lt;meta name="apple-mobile-web-app-capable" content="yes" /&amp;gt;[/HTML]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;But... since I'm trying to make the user experience as consistent as possible (and not force users to create shortcuts) I need to hide the address bar in either case (and not use up valuable screen real estate).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Everything I've found so far relies on "scrolling" to the top of the page or setting the height of the page body to a few pixels larger than what is really needed.&amp;nbsp; In a map app, scrolling doesn't apply and the map element is loaded as height:100%... setting the height to 101% or higher doesn't work either (believe me, I've tried).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here's what I've found so far (none of which seem to work in mobile Safari on an iPhone):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;1) Adding this meta link in the head although the user-scalable=yes is contrary to the Esri JavaScript samples (where they list user-scalable=0):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [HTML]&amp;lt;meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=yes;" /&amp;gt;[/HTML]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;2) Using straight JS to "scroll" to the top of the page&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; function page_Load() { &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setTimeout(function() { window.scrollTo(0, 1); }, 100); &amp;nbsp;&amp;nbsp;&amp;nbsp; } &amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;3) Wrapping the body in jQuery and using that toolkit to do the same thing as #2:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $('body').scrollTop(1); &amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So far, none of these things are working... does anyone know how to successfully hide the address bar automatically (while the device is oriented in portrait)?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Apr 2013 19:05:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-address-bar-on-map-page-load-in-mobile-device/m-p/314450#M28921</guid>
      <dc:creator>NickO_Day</dc:creator>
      <dc:date>2013-04-12T19:05:12Z</dc:date>
    </item>
    <item>
      <title>Re: Hide address bar on map/page load in mobile device?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-address-bar-on-map-page-load-in-mobile-device/m-p/314451#M28922</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I haven't dealt with this but a quick Google search revealed &lt;/SPAN&gt;&lt;A href="http://xme.im/display-fullscreen-website-using-javascript"&gt;this&lt;/A&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Apr 2013 21:42:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-address-bar-on-map-page-load-in-mobile-device/m-p/314451#M28922</guid>
      <dc:creator>SteveCole</dc:creator>
      <dc:date>2013-04-12T21:42:09Z</dc:date>
    </item>
    <item>
      <title>Re: Hide address bar on map/page load in mobile device?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-address-bar-on-map-page-load-in-mobile-device/m-p/314452#M28923</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Steve,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for the input... it wasn't the solution that I was looking for, but still a cool little bit of code that will come in handy.&amp;nbsp; I can imagine using the full screen code you found will be useful when doing presentations on a large screen (when hiding the browser and rest of the desktop is smart).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I ended up finding the following slick bit of code that works perfectly:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A class="jive-link-external-small" href="http://menacingcloud.com/source/js/FlameAutoScroll.js" rel="nofollow" target="_blank"&gt;http://menacingcloud.com/source/js/FlameAutoScroll.js&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Problem solved!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 15 Apr 2013 16:05:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/hide-address-bar-on-map-page-load-in-mobile-device/m-p/314452#M28923</guid>
      <dc:creator>NickO_Day</dc:creator>
      <dc:date>2013-04-15T16:05:58Z</dc:date>
    </item>
  </channel>
</rss>

