Open a window

2012-07-02 Thread afaque_khan_2...@yahoo.com
Hi,

I want to open a small window with a text box on the click of a button on
another page.
After the user enters some information in the text box , on the click of a
button the page must close a submit the original page.
Is there any way of doing this.

Plz help.

--
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Open-a-window-tp5714237.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Open a window

2012-07-02 Thread afaque_khan_2...@yahoo.com
I know, well i'm new to this.
Anyways i get the idea.

Thanks!



--
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Open-a-window-tp5714237p5714244.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Multiple Submits and Ajax Form

2012-06-11 Thread afaque_khan_2...@yahoo.com
Thanks for the response.
I tried what you described. The functionality works. But, even though the
event handler function of the submit button bookTrade returns other some
page, I have an impression that it is an ajax form submit. This is because
on using the object  Request defined in the java file, i see that the
.isXHR() returns always true.

What I want is that the bookTrade button should submit the page normally,
and there should not be any ajax animations.

--
Page in TML
--
div t:type=zone t:id=formZone
form class=creationForm t:zone=formZone t:type=form
t:id=orderClaculateValue method=postt:errors /
input t:type=textfield t:id=price t:value=price/
input t:type=textfield t:id=quantity t:value=quantity /
input t:type=textfield t:id=amount t:value=amount t:size=5/
input t:type=textfield t:id=counterparty t:value=counterparty /
.
.
input t:type=Submit t:id=calculate value=Calculate/
.
.
input t:id=bookTrade value=Finalise t:type=submit/

/form
/div

.java

@InjectPage
private OrderFinalise orderFinalisePage;

@Component
private Submit calculate;

@Component
private Submit bookTrade;

@Component(id=formZone)
private Zone formZone;

@Inject
private Request request;

void onSelectedFromBookTrade() {

formEventReturn = orderFinalisePage; // go to AnotherPage
}

void onSelectedFromCalculate() {

amount = quantity * price;
formEventReturn = formZone.getBody(); // stay on this page
}

Object onSuccessFromOrderClaculateValue() {
   
//if(request.isXHR())
//{
//   return formZone.getBody(); // AJAX request, return zone body
//}
//else
//{
//  return orderFinalisePage; // non-AJAX request, redraw current 
page
//}
  
   return formEventReturn;  
}

--

--


--
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Multiple-Submits-and-Ajax-Form-tp5713699p5713767.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Multiple Submits and Ajax Form

2012-06-07 Thread afaque_khan_2...@yahoo.com
Hi,

I am developping a form where I need two submits.
The first one does small calculation(addition and multiplication) based on
the values provided by the user.
The second submit uses these value calculated by the first submit to call
some webservices, if this call is succesfull the user is directed to new
page.
I want to implement the first submit as ajax submit, and the second submit a
normal submit.
The two submit buttons are in the same form.

In short i want to do a normal submit to an ajax form.

Can someone please help me out giving an example of how this could be
implemented.

Thanks in advance,
Afaque

--
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Multiple-Submits-and-Ajax-Form-tp5713699.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org