Monday, July 29, 2013

APEX Mobile - iPhone 5 Web App in Fullscreen

The default Mobile Theme (50) in APEX renders just fine in Safari. It uses the full height of my iPhone 5, but when I added the app to my Home screen and ran it from there, it didn't render in fullscreen mode.

Turns out that the iPhone 5 doesn't like the meta info.
If you take out the "width=device-width" from the meta name="viewport" part it renders in full screen.

width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">

Changed to:

Note that you have to delete the icon from your home screen first and add it again after making the above change. (cache issue)

There's a nice post by Kyle Larson which goes into more detail on the above and explains how to work with startup screens on the iPhone 5.

Sunday, July 28, 2013

Make APEX Plugin source read/write

I really like the Flot Pie Chart plugin that came with the APEX sample applications (see this blog post in which apps this plugin is used).

But when I wanted to make changes to it, I couldn't... the PL/SQL Code was read-only.

To make the source read/write again you need to delete the reference to the Master Plug-in.
If you export the plugin and open it in your text editor search for "p_reference_id" and set that to null (instead of the number).

wwv_flow_api.create_plugin (

  ,p_reference_id => null

In case you wonder why I want to change that plugin; the plugin is great, but there's a newer version available of the Flot Charts which holds some nice improvements and the current plugin is not mobile compatible and responsive.