Page 1 of 2
URL opening with link component
Posted: Sat Jan 03, 2015 9:30 pm
by Istvan
Hi,
I have a RSS page in my app. I would like to open the source page inappbrowser or on new page with a back to app function.
Actually im use a link component and when tap the link then go to the web page without navigation or back button. I cannot navigate from this page at all.
How can i get a back button or other solution to back navigate?
Thanks
URL opening with link component
Posted: Sun Jan 04, 2015 1:24 pm
by Illya Stepanov
Hi -
Please check InAppBrowser documentation page to learn more about the component, and any other settings and options.
URL opening with link component
Posted: Tue Jan 06, 2015 8:49 am
by Istvan
Hi Illya
It was the first
but I cannot use togheter with link component 
URL opening with link component
Posted: Tue Jan 06, 2015 12:31 pm
by M&M
hi Istvan,
You can store the value / link that the user has clicked and then navigate to another page. In that page, in either the load event (preferably show event), read from that local storage variable ( or global javascript variable)and navigate to that page...something like this
Page show event
window.open('http://www.google.com");
Cheers,
M&M
URL opening with link component
Posted: Tue Jan 06, 2015 1:10 pm
by M&M
I mean
Page show event
var navToURL = localStorage.getItem('saved_url');
window.open(navToURL);
And on this page you can have a header or a footer with a button. The button can have a simple JS script like history.back(); That should take you back to the page from where you landed on this page.
P.N: Remember to choose the correct target as described in http://wiki.apache.org/cordova/InAppB...
Cheers,
M&M
URL opening with link component
Posted: Fri Jan 09, 2015 5:22 am
by Yurii Orishchuk
Hi Istvan,
You can follow these steps:
add "click" event handler.
Set action - "Run javascript".
Populate this action with following JS code:
pre
var link = jQuery(this);
window.open(link.attr("href"), "_blank");
arguments[0].stopPropagation();
arguments[0].preventDefault();
/pre
Details: http://prntscr.com/5q86bi/direct
Regards.
URL opening with link component
Posted: Fri Jan 09, 2015 9:54 am
by Istvan
Thanks Yurii!
Unfortunatly I see now only... the source webpage is terrible on mobile
not responsive and very unique and an other person did it. I cannot change.
Can I somehow get the page source into appery local variable (base on link)? Then I can cut out the useful content parts and show in app ...
Thanks
István
URL opening with link component
Posted: Fri Jan 09, 2015 11:44 am
by Ihor Didevych
Hi Istvan,
You can make service that makes a simple GET to the page, the response area of that service will be needed page
URL opening with link component
Posted: Fri Jan 09, 2015 6:31 pm
by Istvan
Hi Ihor
... response is invalid ...
.
Do you have a working solution?
URL opening with link component
Posted: Mon Jan 12, 2015 3:38 am
by Yurii Orishchuk
Hi lstvan,
Use "appery.io" proxy(to get work in browser).
Ignore "invalid response" and use "complete" service datasource event handler. Here is a code example:
pre
var resultResponse = jqXHR.responseText;
//You can find this response in console. (on device use WEINRE debugger).
console.log("resultResponse = " + resultResponse);
/pre
Regards.