0

Pass string values from java to zul

asked 2014-10-24 14:44:24 +0800

jackbauer324242 gravatar image jackbauer324242
1

Hi I have a IFrame where I want to display a form using prepopulated values. How Can I achieve this? I need to send a data form the java file.

I am doing this as shown below

Java: final Div div = new Div();

    final HtmlBasedComponent content = div; 

    final Iframe iFrame = new Iframe("/myproject/checkout/deliveryAddress.zul?" + "customerName=Jitehs&phoneNumber=06546556498494&[email protected]");
    iFrame.setParent(content);

....

ZUL: <window ....<="" p="">

...... shadow="false"> <zscript> customerName = Executions.getCurrent().getParameter("customerName"); phoneNumber = Executions.getCurrent().getParameter("phoneNumber"); email = Executions.getCurrent().getParameter("email"); </zscript>

<h:form id="hopPostForm" action="${postUrl}" method="POST"> <grid id="grid" visible="false"> <rows> <row> debugMode <textbox name="customerName" value="${customerName}"/> </row> . . . . </rows> </grid>

</window>

delete flag offensive retag edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2014-10-25 16:30:16 +0800

Darksu gravatar image Darksu
1991 1 4

Hello jackbauer324242,

After searching the issue, i may have found a solution that is described at the following url:

http://stackoverflow.com/questions/19286812/variable-in-iframe-with-zk

The summary is that you should use url parameteres in order to set the variables.

Best Regards,

Darksu

link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
1 follower

RSS

Stats

Asked: 2014-10-24 14:44:24 +0800

Seen: 34 times

Last updated: Oct 25 '14

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More