Page 1 of 1

[RPG]Retreive the current URL

Posted: Wed Aug 27, 2014 6:40 pm
by MegumiSawada
Hi,

Is there any way to retreive the current URL of imbedded webview in formview?

You can define start url for imbedded webview in a formview(for example, http://www.lansa.com).
Then user can move to other website on that webview(for example, http://www.lansa.jp/index.htm).

Is it possible to retreive the current URL of it then ?(for example, http://www.lansa.jp/index.htm)

I tried it with
WRKURL = LRNG_GetPropAsStr('/Form.Fields.SITE1.URL');
but it seems it doesn't work.

I appreciate your kind advice.

Regards,
Megumi Sawada

Re: [RPG]Retreive the current URL

Posted: Thu Aug 28, 2014 11:17 am
by MarkDuignan
This might be possible with some JavaScript ECL. You would have to create some sort of web page/frame container to run the web pages in and then set the current URL into a shared state variable. The complexity is that the web browser is out on the client and your RPG program is on the server – so you have to pick up the value on the client and send it to the server.

Even attempting this is a moderately complex task – and there is no guarantee that it will succeed or that it will exactly match the requirement.
How important is the requirement -versus- the possible complexity and cost of implementing it?

One question – are the web pages owned by the customer/client – or can they be any web pages anywhere?
I’m asking because if they are owned there is also a possibility of approaching this the other way around – by getting the web page(s) to post something that tells the server who is where.

Re: [RPG]Retreive the current URL

Posted: Fri Aug 29, 2014 4:14 pm
by MegumiSawada
Hi Mark,

Thank you for your reply.

I see.
I'll ask our customer for more detailed requirement and let you know if more information/consideration required.

Thank you!

Megumi