Ted L
Posts: 0
Joined: Tue Feb 19, 2013 8:03 am

refresh Panel contents on mobile camera success

Hi,

Is there a simple way to refresh Panel contents without refreshing the entire page?

I would like to have a Panel refresh after mobile camera success or on click.

I can't use full page refresh because it's the same page that the camera image is mapped to and if I refresh the whole page my app freezes.

Thanks

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

refresh Panel contents on mobile camera success

Hello! If you want to refresh a few components on screen you would need to refresh each component. For example:

Radio buttons - Tiggzi("mobileradiogroupName").checkboxradio("refresh");

Select menus Tiggzi("mobileselectmenuName").selectmenu("refresh");

More you can find here http://jquerymobile.com/demos/1.2.0/

Ted L
Posts: 0
Joined: Tue Feb 19, 2013 8:03 am

refresh Panel contents on mobile camera success

Hi Marina,

Thanks for the code examples and the link... awesome!

I'm going to be snowed in, so I will have plenty of time to look through the demos :)

Deon
Posts: 0
Joined: Sun Jun 30, 2013 6:00 am

refresh Panel contents on mobile camera success

Hi

I have tried this but it does not work.

Appery ("panel_8").panel("refresh");

The panel does not refresh

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

refresh Panel contents on mobile camera success

Hello! code.panel("refresh")/code is the method to refresh side panel http://jquerymobile.com/demos/1.3.0-b..., not for refreshing panel component. Panel component doesn't need to be refreshed - it's span or div. Could you clarify what are you going to do with your code?

Deon
Posts: 0
Joined: Sun Jun 30, 2013 6:00 am

refresh Panel contents on mobile camera success

Hi Marina

Thank you for your quick response!

I have added a barcode scanner to a page and want to browse to the URL within the app. I do not want to launch an external browser. This seems to e the only way I can accomplish this as other methods launches the browser outside of the app.

So what I am doing, is storing the scanned QR (Webite URL) as a variable to local storage and then want to refresh the panel with the Iframe to display the wesite within the IFrame.

Deon
Posts: 0
Joined: Sun Jun 30, 2013 6:00 am

refresh Panel contents on mobile camera success

I do not realy want to use IFRAME. I need to open a browser in the app. As I unerstand from other posts, there is a way to achieve this but not for Iphone as the ack button is disabled.

I have seen this work in other apps. So there must be a way.

What aout PhoneGap API "InAppBrowser" uses open.window. Open.Window does not work at all for me.

My only workaround is this...

window.plugins.childBrowser.showWebPage(localStorage.getItem("BarcodeValue"), { showLocationBar: false });

However that loads browser outside app.

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

refresh Panel contents on mobile camera success

childBrowser is a part of your app, but it covers entire screen. If you don't like it you can use iframe, but you can't handle iframe content using JS. It's like separate page inside your app page. You can just reload it:
codeAppery("panelName")&#46;html('<iframe src="http:&#47;&#47;appery&#46;io" width="250" height="250"><&#47;iframe>');/code

Deon
Posts: 0
Joined: Sun Jun 30, 2013 6:00 am

refresh Panel contents on mobile camera success

Hi Marina
Thank you. It seems like childbrowser opened a separate browser with navigational address bar and no header. However when I hit the back button, I can see this is InApp browsing. Is there a way to get a header for the childBrowser?

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

refresh Panel contents on mobile camera success

Unfortunately no.

Return to “Issues”