Re: [S2] Opening a new window upon a link click without Javascript

2008-01-03 Thread Gabriel Belingueres
AFAIK, the  tag is best used when designing ajax applications,
meaning the usual interaction is to update the same browser window.

I would stay with the common HTML anchor tag to open a new window.

Gabriel


2008/1/3, Al Sutton <[EMAIL PROTECTED]>:
> Heres channelge for the day...
>
> I have a page which contains a link, when the user clicks the link they get
> a PDF which they need to go off and do something with (not part of the
> webapp).
>
> What I'd like to do is open a new browser window with the PDF in and retain
> the page with link in the original window without using JavaScript.
>
> In HTML I can do this using target="_blank" in the  tag, but with the
>  tag there is no ability to specify the target attribute.
>
> As a further mind bend there is a targets attribute for  in the tld for
> 2.0.11, but it doesn't get mentioned in the documentation and appears not to
> be processed by the tag processing code (so maybe the tld needs a tidy).
>
> Anyone got any thoughts?
>
> Al.
>
> P.S. This isn't a biggie for me as I'm going to use;
>
>  value="step.name"/>
>
> instead of a s:a solution for the moment, it just feels like s:a is missing
> some functionality if I have to revert back to switch between s:a and HTMLs
> a tag.
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[S2] Opening a new window upon a link click without Javascript

2008-01-03 Thread Al Sutton
Heres channelge for the day...
 
I have a page which contains a link, when the user clicks the link they get
a PDF which they need to go off and do something with (not part of the
webapp).
 
What I'd like to do is open a new browser window with the PDF in and retain
the page with link in the original window without using JavaScript.
 
In HTML I can do this using target="_blank" in the  tag, but with the
 tag there is no ability to specify the target attribute.
 
As a further mind bend there is a targets attribute for  in the tld for
2.0.11, but it doesn't get mentioned in the documentation and appears not to
be processed by the tag processing code (so maybe the tld needs a tidy).
 
Anyone got any thoughts?
 
Al.
 
P.S. This isn't a biggie for me as I'm going to use;
 


instead of a s:a solution for the moment, it just feels like s:a is missing
some functionality if I have to revert back to switch between s:a and HTMLs
a tag.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: opening a new window if validated

2007-11-20 Thread Pavel Sapozhnikov
Hey Adam thanks. So basically one of the things I did was when I am on page
x I validate using client side JS validation either written myself or
html:javascript doesn't really metter but both of those two methods pop up
an alert and doesn't actually put it right in the page like html:errors
does. But then yeah it actually works I still have target there and it opens
a new window only when validation succeded thats fine is there any way to
make javascript display html:errors like right in page and not in a pop up I
looked at html:errors it doesn't have an id or styleId attribute which means
I can't do my document.getElementByID('id').innerHTML = 'some error'. So
what do you recommend. By the way thanks for your input.

Pavel

On Nov 19, 2007 5:38 PM, Adam Gordon <[EMAIL PROTECTED]> wrote:

> It could actually be both.  I assume you are using both client and
> server side JavaScript validation (at the very least you should be doing
> server side since HTML pages can be manipulated).
>
> So, assuming you are doing both, you need the page you submitted the
> data on to go somewhere because you want to chain the action, i.e., you
> want to have another window open.  One way to do this is to have the
> main page come back and set a request attribute that indicates you are
> to open the pop-up window.  In J/S land in your JSP (inside a 

RE: opening a new window if validated

2007-11-19 Thread Adam Gordon
It could actually be both.  I assume you are using both client and
server side JavaScript validation (at the very least you should be doing
server side since HTML pages can be manipulated).

So, assuming you are doing both, you need the page you submitted the
data on to go somewhere because you want to chain the action, i.e., you
want to have another window open.  One way to do this is to have the
main page come back and set a request attribute that indicates you are
to open the pop-up window.  In J/S land in your JSP (inside a 

opening a new window if validated

2007-11-19 Thread Pavel Sapozhnikov
Hi I have a question. I am not sure if this is a Struts question or an HTML
question so here we go. I have a form on page x I submit the form validation
failed it goes back to the page x which is fine but then if validated true
it should open a new window with the stuff that should be there. So again I
am not sure if this is Struts question or HTML question I tried doing
onsubmit="validateSomething()" and then that would do javascript validation
but then it didn't display my html:errors. So any help would be really
appreciated. Thanks.


-- 
Pavel Sapozhnikov
xFact, Inc
[EMAIL PROTECTED]


Re: Opening a new window

2006-01-12 Thread Aldo Vadillo Batista
I think you can use javascript for accessing to struts html:hidden variables.

12 Jan 2006 14:59:49 -, rahul  kshirsagar <[EMAIL PROTECTED]>:
> Hi,
>
> I am using struts in my application.I have one parent jsp from which i am 
> opening a new window.Now i want to pass some value from this child window and 
> close the same.
> How to pass this value from child to parent jsp and also retain values in 
> parent jsp?
> Which is the efficient way to implement the same?
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Opening a new window

2006-01-12 Thread rahul kshirsagar
Hi,

I am using struts in my application.I have one parent jsp from which i am 
opening a new window.Now i want to pass some value from this child window and 
close the same.
How to pass this value from child to parent jsp and also retain values in 
parent jsp?
Which is the efficient way to implement the same?  


Re: Opening a New window

2006-01-12 Thread Rick Reumann

rahul kshirsagar wrote the following on 1/12/2006 8:36 AM:

Hi,

Do i need to call action class on submit

> of new jsp?

I wasn't able to follow all of your original post, but in my opinion, 
you should always go through an Action, even if it's the the default 
ActionForward. This way, if later on you truly need to do some 
processing in a custom Action you just change you action mapping and 
don't need to change any of your jsp links.


--
Rick

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Opening a New window

2006-01-12 Thread rahul kshirsagar
Hi,

I am using struts in my application.I have one JSP in which i have "search" and 
"submit" button.I am opening a new window on click of "search" and populating a 
jsp.Now i want to pass a value from this new jsp to old jsp and also want to 
retain data in old jsp.I am not able to pass the value back to old jsp?Do i 
need to call action class on submit of new jsp?

Can you provide me the solution for the same?