on 09-16-2015 11:41 AM
Hi all,
i'm trying to read URL parameters in Screen Personas 3.0 via JavaScript. I passed a parameter "matnr=..." to the URL and want to read it via script to skip my first screen by automatically filling the fields and execute.
I tried several things until i found out that the javascript object location does not contain any of the parameters. location.host and location.pathname both look good, but they don' contain any parameter of course. But neither location.search nor location.hash are filled.
I printed out "location" on my flavor and found out that the URL ends with a "#" where normally the parameter section would have begun starting with "?". Did anyone find a solution for this right now? Are there any other objects i could use to get the URL parameters in Screen Personas?
Appreciate any help.
Best regards,
Christoph
hi christoph,
I guess the solution provided here will be beter:
Filling Fields through URL Parameters - SAP Imagineering - SCN Wiki
Regards,
Sushant
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your replies! The guide from the wiki worked fine for me, i didn't test to reference the parent url so far.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Christoph,
Hope you are safe & well.
I am working on a similar requirement (posted my Q here). Could you please let me know (the code snippet) how you were able to access url parameters?
-Thanks/ Sai
Hi Christoph,
The flavor itself is running inside of an iFrame. Thus, the script is reading the URL of the iFrame and not the URL that is in the browser's URL bar. So, target the parent in order to read URL parameters.
I hope this helps,
Daniel Sanchez
Consultant
SAP America, Inc.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.