using html:form with el logic tags

2004-03-25 Thread Simon Pett

Hi,

Can someone tell me why I get an unbalanced error when I try to optionally
use a form tag? 

org.apache.jasper.JasperException: /pages/common/layouts/layout.jsp(56,1)
The end tag /c:when is unbalanced


tiles:useAttribute name=action/
tiles:useAttribute name=focus/

c:choose
c:when test=${focus != 'na'}
html:form action=${action} focus=${focus}
/c:when
c:otherwise
html:form action=${action}
/c:otherwise
/c:choose

...


Using struts 1.1

Thanks
Simon


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



RE: using html:form with el logic tags

2004-03-25 Thread Takhar, Sandeep
I'm going out on a limb here, but usually I wouldn't do the xml like that with 
html:form since it is unbalanced...

You'll have to find a workaround I think...

sandeep

-Original Message-
From: Simon Pett [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 25, 2004 8:31 AM
To: 'Struts Users Mailing List'
Subject: using html:form with el logic tags



Hi,

Can someone tell me why I get an unbalanced error when I try to optionally
use a form tag? 

org.apache.jasper.JasperException: /pages/common/layouts/layout.jsp(56,1)
The end tag /c:when is unbalanced


tiles:useAttribute name=action/
tiles:useAttribute name=focus/

c:choose
c:when test=${focus != 'na'}
html:form action=${action} focus=${focus}
/c:when
c:otherwise
html:form action=${action}
/c:otherwise
/c:choose

...


Using struts 1.1

Thanks
Simon


-
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]



Suppresing the generation of blank lines while using logic tags - Ver 1.0.2

2004-02-25 Thread Pranay Parsatwar
 

Hello,

 

We are facing problem of jsp file size exceeding to more than 5 MB at
runtime. The jsp file is full of struts tag with lot many logic:equal,
notEqual in the code. The compiled html when generated takes a lot of
time for browser rendering because of the file size. Looking at the html
source generated it seems the tags generates lots of blank line were
ever used. If the source is modified to remove all the blank lines, the
size reduces to 2 mb.

 

I would appreciate any help on this issue.

 

Thanks in advance.

Regards
Pranay Parsatwar 
MphasiS India
2nd Floor,, The Leela Business Park
Andheri Kurla Road,
Andheri (East)
Mumbai - 400 059
Tel: (91)-22-5677
 http://www.mphasis.com/ http://www.mphasis.com/

 



RE: Suppresing the generation of blank lines while using logic tags - Ver 1.0.2

2004-02-25 Thread Karr, David
It's the newline between % and % that is causing you problems (not
to mention the design of your page, but that's a different matter).  If
you do things like:

... %ns:tagname stuff=value
%%ns:nothertag morestuff=morevalue
%%...

Then you will reduce the newlines in your output.  This gets annoying to
read, however.

-Original Message-
From: Pranay Parsatwar [mailto:[EMAIL PROTECTED] 

We are facing problem of jsp file size exceeding to more than 5 MB at
runtime. The jsp file is full of struts tag with lot many logic:equal,
notEqual in the code. The compiled html when generated takes a lot of
time for browser rendering because of the file size. Looking at the html
source generated it seems the tags generates lots of blank line were
ever used. If the source is modified to remove all the blank lines, the
size reduces to 2 mb.

I would appreciate any help on this issue.

Thanks in advance.

Regards
Pranay Parsatwar 
MphasiS India
2nd Floor,, The Leela Business Park
Andheri Kurla Road,
Andheri (East)
Mumbai - 400 059
Tel: (91)-22-5677
 http://www.mphasis.com/ http://www.mphasis.com/

 


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



Re: Suppresing the generation of blank lines while using logic tags - Ver 1.0.2

2004-02-25 Thread Adam Hardy
On 02/25/2004 03:04 PM Pranay Parsatwar wrote:
We are facing problem of jsp file size exceeding to more than 5 MB at
runtime. The jsp file is full of struts tag with lot many logic:equal,
notEqual in the code. The compiled html when generated takes a lot of
time for browser rendering because of the file size. Looking at the html
source generated it seems the tags generates lots of blank line were
ever used. If the source is modified to remove all the blank lines, the
size reduces to 2 mb.
There is a Jasper servlet option which will remove the blank lines. 
Check for the trimSpaces attribute on the jasper servlet in the 
conf/web.xml config.

However it is still going to take processing time to remove the white 
space, so it might not be the enhancement you are hoping for.

Adam
--
struts 1.1 + tomcat 5.0.16 + java 1.4.2
Linux 2.4.20 Debian
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Suppresing the generation of blank lines while using logic tags -

2004-02-25 Thread rick
Use Apache and mod_deflate and mod_gzip.  There are also Filters available to
remove whitespace, but all of them have the problem where they'll modify code
within a lt;pregt; tag or style.

Rick DeBay

On Wed, 25 Feb 2004 06:19 , Karr, David [EMAIL PROTECTED] sent:

It's the newline between % and 
to mention the design of your page, but that's a different matter).  If
you do things like:

... 
%
%

Then you will reduce the newlines in your output.  This gets annoying to
read, however.

-Original Message-
From: Pranay Parsatwar
[EMAIL PROTECTED]','','','')[EMAIL PROTECTED] 

We are facing problem of jsp file size exceeding to more than 5 MB at
runtime. The jsp file is full of struts tag with lot many logic:equal,
notEqual in the code. The compiled html when generated takes a lot of
time for browser rendering because of the file size. Looking at the html
source generated it seems the tags generates lots of blank line were
ever used. If the source is modified to remove all the blank lines, the
size reduces to 2 mb.

I would appreciate any help on this issue.

Thanks in advance.

Regards
Pranay Parsatwar 
MphasiS India
2nd Floor,, The Leela Business Park
Andheri Kurla Road,
Andheri (East)
Mumbai - 400 059
Tel: (91)-22-5677
 http://www.mphasis.com/ http://www.mphasis.com/

 


-
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]



more than one condition using logic tags...

2003-10-29 Thread VKeswani
Hello,

I asked this before - 
Is it possible to have more than one condition using struts logic 
tags...like

If A  B  C then {
do something...
} 


how to achieve this in the jsp using logic tags?
Please help

Re: more than one condition using logic tags...

2003-10-29 Thread Jeff Kyser
sure - just nest them.

On Wednesday, October 29, 2003, at 09:38  AM, [EMAIL PROTECTED] 
wrote:

Hello,

I asked this before -
Is it possible to have more than one condition using struts logic
tags...like
If A  B  C then {
do something...
}
how to achieve this in the jsp using logic tags?
Please help


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


Re: more than one condition using logic tags...

2003-10-29 Thread Sasha Borodin
Or you could use the JSTL conditional tag:

c:if test=${condition1 AND condition2 AND condition3}
your html
/c:if

-Sasha

On 10/29/03 09:43, Jeff Kyser [EMAIL PROTECTED] wrote:

 sure - just nest them.
 
 On Wednesday, October 29, 2003, at 09:38  AM, [EMAIL PROTECTED]
 wrote:
 
 Hello,
 
 I asked this before -
 Is it possible to have more than one condition using struts logic
 tags...like
 
 If A  B  C then {
 do something...
 }
 
 
 how to achieve this in the jsp using logic tags?
 Please help
 
 
 -
 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]



Re: more than one condition using logic tags...

2003-10-29 Thread David Graham

--- [EMAIL PROTECTED] wrote:
 Hello,
 
 I asked this before - 
 Is it possible to have more than one condition using struts logic 
 tags...like
 
 If A  B  C then {
 do something...
 } 

The JSTL provides this capability:

c:if test=${A  B  C}
  do something
/c:if

http://java.sun.com/products/jsp/jstl/

David

 
 
 how to achieve this in the jsp using logic tags?
 Please help


__
Do you Yahoo!?
Exclusive Video Premiere - Britney Spears
http://launch.yahoo.com/promos/britneyspears/

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



Re: more than one condition using logic tags...

2003-10-29 Thread VKeswani
Thanks all...




David Graham [EMAIL PROTECTED]
10/29/2003 10:06 AM
Please respond to Struts Users Mailing List

 
To: Struts Users Mailing List [EMAIL PROTECTED]
cc: 
Subject:Re: more than one condition using logic tags...



--- [EMAIL PROTECTED] wrote:
 Hello,
 
 I asked this before - 
 Is it possible to have more than one condition using struts logic 
 tags...like
 
 If A  B  C then {
 do something...
 } 

The JSTL provides this capability:

c:if test=${A  B  C}
  do something
/c:if

http://java.sun.com/products/jsp/jstl/

David

 
 
 how to achieve this in the jsp using logic tags?
 Please help


__
Do you Yahoo!?
Exclusive Video Premiere - Britney Spears
http://launch.yahoo.com/promos/britneyspears/

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





More than one condition using struts logic tags???

2003-10-27 Thread VKeswani
Hello,

I have a little query -

How can I check for more that one condition using struts logic tags? like 

if (A  B  C) {
do something.
}

how do I achieve the same using struts logic tags?

Re: More than one condition using struts logic tags???

2003-10-27 Thread Craig R. McClanahan
[EMAIL PROTECTED] wrote:

Hello,

I have a little query -

How can I check for more that one condition using struts logic tags? like 

if (A  B  C) {
do something.
}
how do I achieve the same using struts logic tags?
 

You can do an and test by nesting logic:xxx tags inside each other.  
There's no convenient way to do an or test however; that's where the 
expression language in JSTL and JSP 2.0 comes in very handy (if you're 
running on a recent enough servlet container to support them).

Craig



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


logic tags

2003-10-24 Thread mohamed ebrahim faisal




E.FAISAL

Hi

	I would like to display the form data in JSP using logic:iterate tags.

Consider the following situation

ArrayList ar = form.getInfoContents();

for(int i=0;iar.length;i++)
{
   HashMap row = (HashMap) ar.get(i);
	tr
  tdhtml:text property=name value=%=(String) row.get(name) % /
  tdhtml:text property=age value=%=(String) row.get(age) % /
  tdhtml:text property=address value=%=(String) row.get(address) 
% /

  ...
..
/tr
}
In the above code i am getting a property of type ArrayList whose elements 
are of type HashMap, where each HashMap object represents a record.

	It works fine , but i want above code purely in struts tag logic:iterate or 
some other technique.

I tried the following and it worked fine

logic:iterate name=beanname id=persons property=infoContents
tr
 logic:iterate name=persons id=row 
td
bean:write name=row /
   /td
  /logic:iterate
/tr
/logic:iterate
But in the above case i am not able to associate every value in the HashMap 
object ie, row to a corresponding property like i got using for loop

tr
  tdhtml:text property=name value=%=(String) row.get(name) % /
  tdhtml:text property=age value=%=(String) row.get(age) % /
  tdhtml:text property=address value=%=(String) row.get(address) 
% /

  ...
..
/tr
please someone help me out and give the approach to solve the problem

regards

faisal

_
Access Hotmail from your mobile now. 
http://server1.msn.co.in/sp03/mobilesms/ Click here.

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


Re: logic tags

2003-10-24 Thread Brad Balmer
Have you looked at the DisplayTag Libray?

http://sourceforge.net/projects/displaytag/

mohamed ebrahim faisal wrote:





E.FAISAL

Hi

I would like to display the form data in JSP using logic:iterate 
tags.

Consider the following situation

ArrayList ar = form.getInfoContents();

for(int i=0;iar.length;i++)
{
   HashMap row = (HashMap) ar.get(i);
tr
  tdhtml:text property=name value=%=(String) row.get(name) 
% /
  tdhtml:text property=age value=%=(String) row.get(age) % /
  tdhtml:text property=address value=%=(String) 
row.get(address) % /

  ...
..
/tr
}
In the above code i am getting a property of type ArrayList whose 
elements are of type HashMap, where each HashMap object represents a 
record.

It works fine , but i want above code purely in struts tag 
logic:iterate or some other technique.

I tried the following and it worked fine

logic:iterate name=beanname id=persons property=infoContents
tr
 logic:iterate name=persons id=row 
td
bean:write name=row /
   /td
  /logic:iterate
/tr
/logic:iterate
But in the above case i am not able to associate every value in the 
HashMap object ie, row to a corresponding property like i got using 
for loop

tr
  tdhtml:text property=name value=%=(String) row.get(name) 
% /
  tdhtml:text property=age value=%=(String) row.get(age) % /
  tdhtml:text property=address value=%=(String) 
row.get(address) % /

  ...
..
/tr
please someone help me out and give the approach to solve the problem

regards

faisal

_
Access Hotmail from your mobile now. 
http://server1.msn.co.in/sp03/mobilesms/ Click here.

-
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]


iterating through hashmap using logic tags

2003-09-25 Thread tarun.matai
Hi,
I have a hash table, I want to iterate through keys of the hashtable and 
display key value pair on the jsp page, how can i do this using logic tags in struts 
tag library.
I need to show keys as well as values on the jsp page.
Regards,
Tarun


DISCLAIMER:
This message contains privileged and confidential information and is intended only for 
the individual named.If you are not the intended recipient you should not 
disseminate,distribute,store,print, copy or deliver this message.Please notify the 
sender immediately by e-mail if you have received this e-mail by mistake and delete 
this e-mail from your system.E-mail transmission cannot be guaranteed to be secure or 
error-free as information could be intercepted,corrupted,lost,destroyed,arrive late or 
incomplete or contain viruses.The sender therefore does not accept liability for any 
errors or omissions in the contents of this message which arise as a result of e-mail 
transmission. If verification is required please request a hard-copy version.

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



RE: iterating through hashmap using logic tags

2003-09-25 Thread Seyhan BASMACI (Internet Yazilimlari Yetkilisi)
try this,

 Action Class  
HashMap  map = new HashMap();
map.put(myKey1,myValue1);
map.put(myKey2,myValue2);
request.setAttribute(map,map);

--- JSP page 

logic:iterate  id=myIterate name=map 
   bean:write  name=myIterate  property=key/
   bean:write  name=myIterate  property=value/
/logic:iterate




-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 25, 2003 12:29 PM
To: [EMAIL PROTECTED]
Subject: iterating through hashmap using logic tags


Hi,
I have a hash table, I want to iterate through keys of the hashtable and 
display key value pair on the jsp page, how can i do this using logic tags in struts 
tag library.
I need to show keys as well as values on the jsp page.
Regards,
Tarun


DISCLAIMER:
This message contains privileged and confidential information and is intended only for 
the individual named.If you are not the intended recipient you should not 
disseminate,distribute,store,print, copy or deliver this message.Please notify the 
sender immediately by e-mail if you have received this e-mail by mistake and delete 
this e-mail from your system.E-mail transmission cannot be guaranteed to be secure or 
error-free as information could be intercepted,corrupted,lost,destroyed,arrive late or 
incomplete or contain viruses.The sender therefore does not accept liability for any 
errors or omissions in the contents of this message which arise as a result of e-mail 
transmission. If verification is required please request a hard-copy version.

-
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]



Iterating Simultaneously over Two Collections with Logic Tags

2003-08-14 Thread Jordan Reed
I've got a JSP that is display a list of information coming from two
different collections and having trouble finding the cleanest way to do it
with the struts tags.

The line I'm struggling with is the bean:define where I'm constructing the
name of the property using a scriptlet and the index from the iterate tag.
It leaves a bad taste in my mouth.

Is there a better way beyond bugging the other developers to combine the
information into a different format that serves my display needs better?


logic:iterate id=primaryRecord name=productSearchViewHelper
property=primaryRecords indexId=i

  bean:define id=secondaryRecord name=productSearchViewHelper
property='%=secondaryRecord[ + i + ]%' /

  bean:write name=primaryRecord property=description/
  bean:write name=secondaryRecord property=description/
  
/logic:iterate

Thanks,
Jordan


-- 
Jordan Reed | http://www.chaosserver.net | [EMAIL PROTECTED]


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



Re: logic tags with mapped properties

2003-08-14 Thread André
Yes, it is supported.

--- André Moreira [EMAIL PROTECTED] wrote:
 Gurus,
 
 do logic tags suport mapped properties?
 
 In other words, I want to have a HashMap wrapped
 inside a java bean and use its values in a tag like
 logic:equal name=beanName
 property=mappedProperty(key) value=true/
 
 Any help is appreciated.
 
 Regards, 
 
 André.
 
 =
 
 O mundo é bom pra quem sabe viver.
 
 __
 Do you Yahoo!?
 Yahoo! SiteBuilder - Free, easy-to-use web site
 design software
 http://sitebuilder.yahoo.com
 

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


=

O mundo é bom pra quem sabe viver.

__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



logic tags with mapped properties

2003-07-31 Thread André
Gurus,

do logic tags suport mapped properties?

In other words, I want to have a HashMap wrapped
inside a java bean and use its values in a tag like
logic:equal name=beanName
property=mappedProperty(key) value=true/

Any help is appreciated.

Regards, 

André.

=

O mundo é bom pra quem sabe viver.

__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



logic tags problem - help!!

2003-07-10 Thread Joe Zendle
Help!! This is a repost. Are there problems with logic:empty tags within
an logic:iterate or am I an idiot? 
===

I'm trying to display a checkbox only if a field is not empty. This
logic is applied in a logic:iterate tag as in the code below. No
matter what the property values are, the checkbox is always displayed as
if the logic check is not made. I have tried logic:empty,
logic:notEmpty, logic:equals, logic:notEquals and I always get the same
result - the checkbox is always displayed.

Thanks in advance.

Joe 

table border=0 cellpadding=0 cellspacing=0 class=form_block
width=544 tr
  td class=form_titleAddress/td
  td class=form_titleDescription/td
  td class=form_titleDelete/td/tr
  logic:iterate id=address indexId=i name=EmailSettingsForm
property=addresses
tr
td
   html:text property='%= addresses[ + i + ].emailAddress %'
/  
/td
td
  html:text property='%= addresses[ + i + ].description %'/
/td
  logic:notEmpty name=address property=emailAddress/
html:checkbox property='%= addresses[ + i + ].deleteFlag
%'/
  /logic:notEmpty
   /td
   /tr
/logic:iterate
tr
td colspan=3nbsp;/td
/tr
tr
td colspan=3h6nbsp;/h6/td
/tr
trtdnbsp;/tdtd class=form_field html:submit
property=btnSubmit value=OK/ html:reset value=Cancel
//tdtdnbsp;/td/tr /table


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



Nesting logic tags

2003-05-31 Thread Kamholz, Keith (corp-staff) USX
Hey,
I'm using a table to display a form, but there's one row that I want to
hide, depending on a previous user selection.
Right now, my code is:

table
tr
td
b
bean:message key=app.label.numberType/: 
/b
/td
td
html:hidden name=ansm property=numberType
write=true/
/td
/tr

logic:equal value=subformat name=ansm property=entryType
tr
td
b
bean:message
key=app.label.subType/: 
/b
/td
td
html:hidden name=ansm property=subType
write=true/
/td
/tr
/logic:equal

tr
td
b
bean:message key=app.label.typeDesc/: 
/b
/td
td
html:text name=ansm property=typeDesc size=50
maxlength=50/
/td
/tr

logic:notEqual value=group name=ansm property=entryType
tr
td
b
bean:message
key=app.label.typeFormat/: 
/b
/td
td
html:text name=ansm property=typeFormat
size=60 maxlength=60/
/td
/tr
tr
td
b
bean:message
key=app.label.tabulatedFormat/: 
/b
/td
td
html:text name=ansm
property=tabulatedFormat size=60 maxlength=60/
/td
tr
td
b
bean:message
key=app.label.lastUsed/: 
/b
/td
td
html:text name=ansm property=lastUsed
size=30 maxlength=30/
/td
/tr
/logic:notEqual

/table

Unfortunately, it doesn't like me nesting the logic tags in the table code.
I've never used the struts nested taglib, would this be an appropriate place
to use it?  If not, does anyone know of a workaround I could use?

Thanks in advance.


~ Keith

http://www.buffalo.edu/~kkamholz



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



RE: Nesting logic tags

2003-05-31 Thread Phillip Qin
If ansm is a member variable of your ActionForm, use

html:hidden property=ansm.entryType

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: May 30, 2003 10:53 AM
To: '[EMAIL PROTECTED]'
Subject: Nesting logic tags

Hey,
I'm using a table to display a form, but there's one row that I want to
hide, depending on a previous user selection.
Right now, my code is:

table
tr
td
b
bean:message key=app.label.numberType/: 
/b
/td
td
html:hidden name=ansm property=numberType
write=true/
/td
/tr

logic:equal value=subformat name=ansm property=entryType
tr
td
b
bean:message
key=app.label.subType/: 
/b
/td
td
html:hidden name=ansm property=subType
write=true/
/td
/tr
/logic:equal

tr
td
b
bean:message key=app.label.typeDesc/: 
/b
/td
td
html:text name=ansm property=typeDesc size=50
maxlength=50/
/td
/tr

logic:notEqual value=group name=ansm property=entryType
tr
td
b
bean:message
key=app.label.typeFormat/: 
/b
/td
td
html:text name=ansm property=typeFormat
size=60 maxlength=60/
/td
/tr
tr
td
b
bean:message
key=app.label.tabulatedFormat/: 
/b
/td
td
html:text name=ansm
property=tabulatedFormat size=60 maxlength=60/
/td
tr
td
b
bean:message
key=app.label.lastUsed/: 
/b
/td
td
html:text name=ansm property=lastUsed
size=30 maxlength=30/
/td
/tr
/logic:notEqual

/table

Unfortunately, it doesn't like me nesting the logic tags in the table code.
I've never used the struts nested taglib, would this be an appropriate place
to use it?  If not, does anyone know of a workaround I could use?

Thanks in advance.


~ Keith

http://www.buffalo.edu/~kkamholz



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


RE: Nesting logic tags

2003-05-31 Thread Kamholz, Keith (corp-staff) USX
The issue isn't getting entryType into the form.  The issue is conditionally
displaying a couple rows in the table/form.  I already have the entryType in
a hidden input earlier in the form.
Input anybody?
I'd really appreciate it.

~ Keith

http://www.buffalo.edu/~kkamholz



-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED]
Sent: Friday, May 30, 2003 11:09 AM
To: 'Struts Users Mailing List'
Subject: RE: Nesting logic tags


If ansm is a member variable of your ActionForm, use

html:hidden property=ansm.entryType

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: May 30, 2003 10:53 AM
To: '[EMAIL PROTECTED]'
Subject: Nesting logic tags

Hey,
I'm using a table to display a form, but there's one row that I want to
hide, depending on a previous user selection.
Right now, my code is:

table
tr
td
b
bean:message key=app.label.numberType/: 
/b
/td
td
html:hidden name=ansm property=numberType
write=true/
/td
/tr

logic:equal value=subformat name=ansm property=entryType
tr
td
b
bean:message
key=app.label.subType/: 
/b
/td
td
html:hidden name=ansm property=subType
write=true/
/td
/tr
/logic:equal

tr
td
b
bean:message key=app.label.typeDesc/: 
/b
/td
td
html:text name=ansm property=typeDesc size=50
maxlength=50/
/td
/tr

logic:notEqual value=group name=ansm property=entryType
tr
td
b
bean:message
key=app.label.typeFormat/: 
/b
/td
td
html:text name=ansm property=typeFormat
size=60 maxlength=60/
/td
/tr
tr
td
b
bean:message
key=app.label.tabulatedFormat/: 
/b
/td
td
html:text name=ansm
property=tabulatedFormat size=60 maxlength=60/
/td
tr
td
b
bean:message
key=app.label.lastUsed/: 
/b
/td
td
html:text name=ansm property=lastUsed
size=30 maxlength=30/
/td
/tr
/logic:notEqual

/table

Unfortunately, it doesn't like me nesting the logic tags in the table code.
I've never used the struts nested taglib, would this be an appropriate place
to use it?  If not, does anyone know of a workaround I could use?

Thanks in advance.


~ Keith

http://www.buffalo.edu/~kkamholz



-
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]



RE: Nesting logic tags

2003-05-31 Thread Phillip Qin
OK. Assume you use nested, your form is called ansm.

nested:form ..

table
tr
tdbbean:message key=app.label.numberType/: /b/td
tdnetsed:hidden property=numberType write=true//td
/tr

nested:equal value=subformat property=entryType
tr
tdbbean:message key=app.label.subType/:
/b/td
tdnested:hidden property=subType write=true/
/td
/tr
/nested:equal


/table
/nested:form

Correct me if I still didn't understand your question.

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: May 30, 2003 11:14 AM
To: 'Struts Users Mailing List'
Subject: RE: Nesting logic tags

The issue isn't getting entryType into the form.  The issue is conditionally
displaying a couple rows in the table/form.  I already have the entryType in
a hidden input earlier in the form.
Input anybody?
I'd really appreciate it.

~ Keith

http://www.buffalo.edu/~kkamholz



-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED]
Sent: Friday, May 30, 2003 11:09 AM
To: 'Struts Users Mailing List'
Subject: RE: Nesting logic tags


If ansm is a member variable of your ActionForm, use

html:hidden property=ansm.entryType

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: May 30, 2003 10:53 AM
To: '[EMAIL PROTECTED]'
Subject: Nesting logic tags

Hey,
I'm using a table to display a form, but there's one row that I want to
hide, depending on a previous user selection.
Right now, my code is:

table
tr
td
b
bean:message key=app.label.numberType/: 
/b
/td
td
html:hidden name=ansm property=numberType
write=true/
/td
/tr

logic:equal value=subformat name=ansm property=entryType
tr
td
b
bean:message
key=app.label.subType/: 
/b
/td
td
html:hidden name=ansm property=subType
write=true/
/td
/tr
/logic:equal

tr
td
b
bean:message key=app.label.typeDesc/: 
/b
/td
td
html:text name=ansm property=typeDesc size=50
maxlength=50/
/td
/tr

logic:notEqual value=group name=ansm property=entryType
tr
td
b
bean:message
key=app.label.typeFormat/: 
/b
/td
td
html:text name=ansm property=typeFormat
size=60 maxlength=60/
/td
/tr
tr
td
b
bean:message
key=app.label.tabulatedFormat/: 
/b
/td
td
html:text name=ansm
property=tabulatedFormat size=60 maxlength=60/
/td
tr
td
b
bean:message
key=app.label.lastUsed/: 
/b
/td
td
html:text name=ansm property=lastUsed
size=30 maxlength=30/
/td
/tr
/logic:notEqual

/table

Unfortunately, it doesn't like me nesting the logic tags in the table code.
I've never used the struts nested taglib, would this be an appropriate place
to use it?  If not, does anyone know of a workaround I could use?

Thanks in advance.


~ Keith

http://www.buffalo.edu/~kkamholz



-
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]


RE: Nesting logic tags

2003-05-31 Thread Michael Ruppin
Struts logic tags work fine nested in HTML table
tags.  Something else must be wrong, perhaps with your
logic tag attributes.  The nested tag library is for
nested BEANS, not for nested tags.  Unless you have
Forms which contain Forms, or Forms with Collections
of Forms, you don't need the nested tab library.

HTH

m

--- Kamholz, Keith   (corp-staff) USX
[EMAIL PROTECTED] wrote:
 The issue isn't getting entryType into the form. 
 The issue is conditionally
 displaying a couple rows in the table/form.  I
 already have the entryType in
 a hidden input earlier in the form.
 Input anybody?
 I'd really appreciate it.
 
 ~ Keith
 
 http://www.buffalo.edu/~kkamholz
 
 
 
 -Original Message-
 From: Phillip Qin [mailto:[EMAIL PROTECTED]
 Sent: Friday, May 30, 2003 11:09 AM
 To: 'Struts Users Mailing List'
 Subject: RE: Nesting logic tags
 
 
 If ansm is a member variable of your ActionForm, use
 
 html:hidden property=ansm.entryType
 
 -Original Message-
 From: Kamholz, Keith (corp-staff) USX
 [mailto:[EMAIL PROTECTED] 
 Sent: May 30, 2003 10:53 AM
 To: '[EMAIL PROTECTED]'
 Subject: Nesting logic tags
 
 Hey,
 I'm using a table to display a form, but there's one
 row that I want to
 hide, depending on a previous user selection.
 Right now, my code is:
 
 table
   tr
   td
   b
   bean:message key=app.label.numberType/: 
   /b
   /td
   td
   html:hidden name=ansm property=numberType
 write=true/
   /td
   /tr
   
   logic:equal value=subformat name=ansm
 property=entryType
   tr
   td
   b
   bean:message
 key=app.label.subType/: 
   /b
   /td
   td
   html:hidden name=ansm property=subType
 write=true/
   /td
   /tr
   /logic:equal
   
   tr
   td
   b
   bean:message key=app.label.typeDesc/: 
   /b
   /td
   td
   html:text name=ansm property=typeDesc
 size=50
 maxlength=50/
   /td
   /tr
   
   logic:notEqual value=group name=ansm
 property=entryType
   tr
   td
   b
   bean:message
 key=app.label.typeFormat/: 
   /b
   /td
   td
   html:text name=ansm property=typeFormat
 size=60 maxlength=60/
   /td
   /tr
   tr
   td
   b
   bean:message
 key=app.label.tabulatedFormat/: 
   /b
   /td
   td
   html:text name=ansm
 property=tabulatedFormat size=60
 maxlength=60/
   /td
   tr
   td
   b
   bean:message
 key=app.label.lastUsed/: 
   /b
   /td
   td
   html:text name=ansm property=lastUsed
 size=30 maxlength=30/
   /td
   /tr
   /logic:notEqual
   
 /table
 
 Unfortunately, it doesn't like me nesting the logic
 tags in the table code.
 I've never used the struts nested taglib, would this
 be an appropriate place
 to use it?  If not, does anyone know of a workaround
 I could use?
 
 Thanks in advance.
 
 
 ~ Keith
 
 http://www.buffalo.edu/~kkamholz
 
 
 

-
 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]
 


__
Do you Yahoo!?
Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
http://calendar.yahoo.com

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



RE: Nesting logic tags

2003-05-31 Thread Kamholz, Keith (corp-staff) USX
Hm
I don't see what would be wrong then.  I'll repost my code.
Any ideas anybody?

table
tr
td
b
bean:message key=app.label.numberType/: 
/b
/td
td
html:hidden name=ansm property=numberType
write=true/
/td
/tr

logic:equal value=subformat name=ansm property=entryType
tr
td
b
bean:message
key=app.label.subType/: 
/b
/td
td
html:hidden name=ansm property=subType
write=true/
/td
/tr
/logic:equal

tr
td
b
bean:message key=app.label.typeDesc/: 
/b
/td
td
html:text name=ansm property=typeDesc size=50
maxlength=50/
/td
/tr

logic:notEqual value=group name=ansm property=entryType
tr
td
b
bean:message
key=app.label.typeFormat/: 
/b
/td
td
html:text name=ansm property=typeFormat
size=60 maxlength=60/
/td
/tr
tr
td
b
bean:message
key=app.label.tabulatedFormat/: 
/b
/td
td
html:text name=ansm
property=tabulatedFormat size=60 maxlength=60/
/td
tr
td
b
bean:message
key=app.label.lastUsed/: 
/b
/td
td
html:text name=ansm property=lastUsed
size=30 maxlength=30/
/td
/tr
/logic:notEqual

/table


~ Keith

http://www.buffalo.edu/~kkamholz



-Original Message-
From: Michael Ruppin [mailto:[EMAIL PROTECTED]
Sent: Friday, May 30, 2003 12:24 PM
To: Struts Users Mailing List
Subject: RE: Nesting logic tags


Struts logic tags work fine nested in HTML table
tags.  Something else must be wrong, perhaps with your
logic tag attributes.  The nested tag library is for
nested BEANS, not for nested tags.  Unless you have
Forms which contain Forms, or Forms with Collections
of Forms, you don't need the nested tab library.

HTH

m

--- Kamholz, Keith   (corp-staff) USX
[EMAIL PROTECTED] wrote:
 The issue isn't getting entryType into the form. 
 The issue is conditionally
 displaying a couple rows in the table/form.  I
 already have the entryType in
 a hidden input earlier in the form.
 Input anybody?
 I'd really appreciate it.
 
 ~ Keith
 
 http://www.buffalo.edu/~kkamholz
 
 
 
 -Original Message-
 From: Phillip Qin [mailto:[EMAIL PROTECTED]
 Sent: Friday, May 30, 2003 11:09 AM
 To: 'Struts Users Mailing List'
 Subject: RE: Nesting logic tags
 
 
 If ansm is a member variable of your ActionForm, use
 
 html:hidden property=ansm.entryType
 
 -Original Message-
 From: Kamholz, Keith (corp-staff) USX
 [mailto:[EMAIL PROTECTED] 
 Sent: May 30, 2003 10:53 AM
 To: '[EMAIL PROTECTED]'
 Subject: Nesting logic tags
 
 Hey,
 I'm using a table to display a form, but there's one
 row that I want to
 hide, depending on a previous user selection.
 Right now, my code is:
 
 table
   tr
   td
   b
   bean:message key=app.label.numberType/: 
   /b
   /td
   td
   html:hidden name=ansm property=numberType
 write=true/
   /td
   /tr
   
   logic:equal value=subformat name=ansm
 property=entryType
   tr
   td
   b
   bean:message
 key=app.label.subType/: 
   /b
   /td
   td
   html:hidden name=ansm property=subType
 write=true/
   /td
   /tr
   /logic:equal
   
   tr
   td
   b
   bean:message key=app.label.typeDesc/: 
   /b
   /td
   td
   html:text name=ansm property

RE: Nesting logic tags

2003-05-31 Thread Michael Ruppin
Well, I'm not an expert, but I can try.  First, the
obvious stuff I assume you know.  ansm must be a bean
you've exposed, right?  If so, then it must have a
getter method, getEntryType().  In order for the
contents within logic:equal to appear, this method
must return subformat [or group].  I *think* that
if the ansm bean were not exposed, or you didn't have
the getter, there'd be an error, so I guess that's not
it.  I would do a bean:write name=ansm
property=entryType\ prior to the logic tags, and
see what happens.

m

--- Kamholz, Keith   (corp-staff) USX
[EMAIL PROTECTED] wrote:
 Hm
 I don't see what would be wrong then.  I'll repost
 my code.
 Any ideas anybody?
 
 table
   tr
   td
   b
   bean:message key=app.label.numberType/: 
   /b
   /td
   td
   html:hidden name=ansm property=numberType
 write=true/
   /td
   /tr
   
   logic:equal value=subformat name=ansm
 property=entryType
   tr
   td
   b
   bean:message
 key=app.label.subType/: 
   /b
   /td
   td
   html:hidden name=ansm property=subType
 write=true/
   /td
   /tr
   /logic:equal
   
   tr
   td
   b
   bean:message key=app.label.typeDesc/: 
   /b
   /td
   td
   html:text name=ansm property=typeDesc
 size=50
 maxlength=50/
   /td
   /tr
   
   logic:notEqual value=group name=ansm
 property=entryType
   tr
   td
   b
   bean:message
 key=app.label.typeFormat/: 
   /b
   /td
   td
   html:text name=ansm property=typeFormat
 size=60 maxlength=60/
   /td
   /tr
   tr
   td
   b
   bean:message
 key=app.label.tabulatedFormat/: 
   /b
   /td
   td
   html:text name=ansm
 property=tabulatedFormat size=60
 maxlength=60/
   /td
   tr
   td
   b
   bean:message
 key=app.label.lastUsed/: 
   /b
   /td
   td
   html:text name=ansm property=lastUsed
 size=30 maxlength=30/
   /td
   /tr
   /logic:notEqual
   
 /table
 
 
 ~ Keith
 
 http://www.buffalo.edu/~kkamholz
 
 
 
 -Original Message-
 From: Michael Ruppin [mailto:[EMAIL PROTECTED]
 Sent: Friday, May 30, 2003 12:24 PM
 To: Struts Users Mailing List
 Subject: RE: Nesting logic tags
 
 
 Struts logic tags work fine nested in HTML table
 tags.  Something else must be wrong, perhaps with
 your
 logic tag attributes.  The nested tag library is for
 nested BEANS, not for nested tags.  Unless you have
 Forms which contain Forms, or Forms with Collections
 of Forms, you don't need the nested tab library.
 
 HTH
 
 m
 
 --- Kamholz, Keith   (corp-staff) USX
 [EMAIL PROTECTED] wrote:
  The issue isn't getting entryType into the form. 
  The issue is conditionally
  displaying a couple rows in the table/form.  I
  already have the entryType in
  a hidden input earlier in the form.
  Input anybody?
  I'd really appreciate it.
  
  ~ Keith
  
  http://www.buffalo.edu/~kkamholz
  
  
  
  -Original Message-
  From: Phillip Qin [mailto:[EMAIL PROTECTED]
  Sent: Friday, May 30, 2003 11:09 AM
  To: 'Struts Users Mailing List'
  Subject: RE: Nesting logic tags
  
  
  If ansm is a member variable of your ActionForm,
 use
  
  html:hidden property=ansm.entryType
  
  -Original Message-
  From: Kamholz, Keith (corp-staff) USX
  [mailto:[EMAIL PROTECTED] 
  Sent: May 30, 2003 10:53 AM
  To: '[EMAIL PROTECTED]'
  Subject: Nesting logic tags
  
  Hey,
  I'm using a table to display a form, but there's
 one
  row that I want to
  hide, depending on a previous user selection.
  Right now, my code is:
  
  table
  tr
  td
  b
  bean:message key=app.label.numberType/: 
  /b
  /td
  td
  html:hidden name=ansm property=numberType
  write=true/
  /td
  /tr
  
  logic:equal value=subformat name=ansm
  property=entryType
  tr

Re: Logic tags and collections?

2003-03-12 Thread niksa_os
 Try struts menu http://sourceforge.net/project/struts-menu.

 Edgar

PAGE NOT FOUND

I try to search at sourceforge.net, but I didn't find anything like
struts-menu.
Where is it?

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



RE: Logic tags and collections?

2003-03-12 Thread Eva Sager
I think he meant http://sourceforge.net/projects/struts-menu

-Original Message-
From: niksa_os [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 12, 2003 6:13 AM
To: Struts Users Mailing List
Subject: Re: Logic tags and collections?


 Try struts menu http://sourceforge.net/project/struts-menu.

 Edgar

PAGE NOT FOUND

I try to search at sourceforge.net, but I didn't find anything like
struts-menu.
Where is it?

-
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]



Logic tags and collections?

2003-03-11 Thread niksa_os
How can I make something like this with Struts or someone have better idea?

I have few Admin: MainAdmin, UserAdmin, EmailAdmin.
MainAdmin can do anything, UserAdmin manage users and emails, and EmailAdmin
make emails only.

So, I need this:
-without Struts, I make Collection in session and

If session.getAdminTypeCollection contain MainAdmin {
do something
If session.getAdminTypeCollection contain UserAdmin OR MainAdmin {
do something
If session.getAdminTypeCollection contain EmailAdmin OR UserAdmin OR
MainAdmin {
do something
} End EmailAdmin
} End UserAdmin
} End MainAdmin

For MainAdmin Collection:
Collection.add(MainAdmin)
Collection.add(UserAdmin)
Collection.add(EmailAdmin)

For UserAdmin Collection:
Collection.add(UserAdmin)
Collection.add(EmailAdmin)

For EmailAdmin Collection:
Collection.add(EmailAdmin)

-do something are links

MainAdmin see all links
UserAdmin see UserAdmin and EmailAdmin links
EmailAdmin only EmailAdmin links

I can't use role or principal or anything from JAAS.

So, I need somehow to check Coolection with logic:present or some others
tags?

Thanks.

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



RE: Logic tags and collections?

2003-03-11 Thread Edgar Dollin
Try struts menu http://sourceforge.net/project/struts-menu.

Edgar

 -Original Message-
 From: niksa_os [mailto:[EMAIL PROTECTED] 
 Sent: Tuesday, March 11, 2003 11:37 AM
 To: 'Struts Users Mailing List'
 Subject: Logic tags and collections?
 
 
 How can I make something like this with Struts or someone 
 have better idea?
 
 I have few Admin: MainAdmin, UserAdmin, EmailAdmin.
 MainAdmin can do anything, UserAdmin manage users and emails, 
 and EmailAdmin make emails only.
 
 So, I need this:
 -without Struts, I make Collection in session and
 
 If session.getAdminTypeCollection contain MainAdmin {
 do something
 If session.getAdminTypeCollection contain UserAdmin OR MainAdmin {
 do something
 If session.getAdminTypeCollection contain EmailAdmin OR 
 UserAdmin OR MainAdmin {
 do something
 } End EmailAdmin
 } End UserAdmin
 } End MainAdmin
 
 For MainAdmin Collection:
 Collection.add(MainAdmin)
 Collection.add(UserAdmin)
 Collection.add(EmailAdmin)
 
 For UserAdmin Collection:
 Collection.add(UserAdmin)
 Collection.add(EmailAdmin)
 
 For EmailAdmin Collection:
 Collection.add(EmailAdmin)
 
 -do something are links
 
 MainAdmin see all links
 UserAdmin see UserAdmin and EmailAdmin links
 EmailAdmin only EmailAdmin links
 
 I can't use role or principal or anything from JAAS.
 
 So, I need somehow to check Coolection with logic:present or 
 some others tags?
 
 Thanks.
 

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



RE: Logic tags and collections?

2003-03-11 Thread Marco Tedone
First of all I would suggest you to reverse the if order so that, it the
first if returns true, you don't' have to perform the other if
statements(Like now, to get to a consistent result, you should perform all
the three if statements); secondly, you could iterate trough the Collection
retrieved from the session[by means of
(java.util.YourCollection)session.getAttribute? By means of bean:define
id=yourInternal name=yourSessionScopeCollectionName
type=java.util.YourCollection?]

and, depending on how many if are satisfied by logic:present, you could
show the consistent links.

My 2 cents.

Marco

 -Original Message-
 From: niksa_os [mailto:[EMAIL PROTECTED] 
 Sent: Tuesday, March 11, 2003 4:37 PM
 To: Struts Users Mailing List
 Subject: Logic tags and collections?
 
 
 How can I make something like this with Struts or someone 
 have better idea?
 
 I have few Admin: MainAdmin, UserAdmin, EmailAdmin.
 MainAdmin can do anything, UserAdmin manage users and emails, 
 and EmailAdmin make emails only.
 
 So, I need this:
 -without Struts, I make Collection in session and
 
 If session.getAdminTypeCollection contain MainAdmin {
 do something
 If session.getAdminTypeCollection contain UserAdmin OR MainAdmin {
 do something
 If session.getAdminTypeCollection contain EmailAdmin OR 
 UserAdmin OR MainAdmin {
 do something
 } End EmailAdmin
 } End UserAdmin
 } End MainAdmin
 
 For MainAdmin Collection:
 Collection.add(MainAdmin)
 Collection.add(UserAdmin)
 Collection.add(EmailAdmin)
 
 For UserAdmin Collection:
 Collection.add(UserAdmin)
 Collection.add(EmailAdmin)
 
 For EmailAdmin Collection:
 Collection.add(EmailAdmin)
 
 -do something are links
 
 MainAdmin see all links
 UserAdmin see UserAdmin and EmailAdmin links
 EmailAdmin only EmailAdmin links
 
 I can't use role or principal or anything from JAAS.
 
 So, I need somehow to check Coolection with logic:present or 
 some others tags?
 
 Thanks.
 

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



How to compare two beans using logic tags

2003-03-07 Thread Renato Romano
Does anyone knows how to compare two beans (or beans properties) using
logic:equal or logic:greaterThan tags ?In the docs it is said that the
value attribute should be a constant value ...
Thanks


Renato Romano
Sistemi e Telematica S.p.A.
Calata Grazie - Vial Al Molo Giano
16127 - GENOVA

e-mail: [EMAIL PROTECTED]
Tel.:   010 2712603
_




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



Re: How to compare two beans using logic tags

2003-03-07 Thread Nicolas De Loof
bean:define id=prop1 name=bean1 property=someProperty /
logic:equals name=bean2 property=anotherProperty value=%= prop1
%
 ...
/logic:equals

Nico.

 Does anyone knows how to compare two beans (or beans properties)
using
 logic:equal or logic:greaterThan tags ?In the docs it is said that
the
 value attribute should be a constant value ...
 Thanks

 
 Renato Romano
 Sistemi e Telematica S.p.A.
 Calata Grazie - Vial Al Molo Giano
 16127 - GENOVA

 e-mail: [EMAIL PROTECTED]
 Tel.:   010 2712603
 _




 
-
 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]



[Q]Logic tags

2003-02-27 Thread Chetan Sahasrabudhe



Hi,
 I am trying to use logic tags to find if the value is 
present in my formbean attribute,
depending on if value is present or not i have to take some action
please check attached code for details.

 
logic:empty name="wigadminwizardform" 
property="sTransactionType" 
html:text property="sTransactionType" size="25" 
maxlength="25"/ 
/logic:empty 
logic:notEmpty name="wigadminwizardform" 
property="sTransactionType" 
bean:write name="wigadminwizardform" 
property="sTransactionType"/ 
/logic:notEmpty

wigadminwizardform is my formbean with session scope. above the code i have 
put aline

jsp:useBean id="wigadminwizardform" scope="session" 
class="wigadmin.struts.forms.WIGAdminWizardForm"/

so my page has a view for the bean.

what is happening in, even if sTransationType is populated i am getting 
text box.
which should appear on page only if sTransactionType is empty.

what can be the problem



RegardsChetan___| 
| The trouble with being punctual 
| is that nobody's there to appreciate 
it.| | 
|___



[Q]Logic tags

2003-02-27 Thread Edgar Dollin
The bean is already in scope.  The name is the name of the bean supplied in 
Your ActionMap, i.e.

action path=/viewschedule 
type=net.bmllc.actions.DataEntry 
name=ViewSchedule 
validate=true 
input=viewschedule.tile
forward name=lookup path=viewschedule.tile /
/action

In the case above the bean attribute name is 'ViewSchedule' which would be
Equivalent to your webadminwizardform in the id attribute of the jsp:useBean
tag.

In other words, the jsp:useBean is redundant and possibly causing a new
Copy of your form bean to be instantiated, tossing the original.

Edgar



Subject:  [Q]Logic tags
From: Chetan Sahasrabudhe chetans () wisorindia ! soft ! net
Date: 2003-02-27 11:47:41
[Download message RAW]

[Attachment #2 (multipart/alternative)]


BlankHi,
I am trying to use logic tags to find if the value is present in my
formbean attribute,
depending on if value is present or not i have to take some action
please check attached code for details.

 logic:empty name=wigadminwizardform
property=sTransactionType
html:text property=sTransactionType size=25
maxlength=25/
/logic:empty
logic:notEmpty name=wigadminwizardform
property=sTransactionType
 bean:write name=wigadminwizardform
property=sTransactionType/
/logic:notEmpty

wigadminwizardform is my formbean with session scope. above the code i have
put aline

jsp:useBean id=wigadminwizardform scope=session
class=wigadmin.struts.forms.WIGAdminWizardForm/

so my page has a view for the bean.

what is happening in, even if sTransationType is populated i am getting text
box.
which should appear on page only if sTransactionType is empty.

what can be the problem



Regards
Chetan

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



Re: [Q]Logic tags

2003-02-27 Thread Chetan Sahasrabudhe
Nope, I removed the tag, no change in behaviour, letz see what might be the
prob.
Thanks

- Original Message -
From: Edgar Dollin [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Sent: Thursday, February 27, 2003 6:30 PM
Subject: [Q]Logic tags


 The bean is already in scope.  The name is the name of the bean supplied
in
 Your ActionMap, i.e.

 action path=/viewschedule
 type=net.bmllc.actions.DataEntry
 name=ViewSchedule
 validate=true
 input=viewschedule.tile
 forward name=lookup path=viewschedule.tile /
 /action

 In the case above the bean attribute name is 'ViewSchedule' which would be
 Equivalent to your webadminwizardform in the id attribute of the
jsp:useBean
 tag.

 In other words, the jsp:useBean is redundant and possibly causing a new
 Copy of your form bean to be instantiated, tossing the original.

 Edgar



 Subject:  [Q]Logic tags
 From: Chetan Sahasrabudhe chetans () wisorindia ! soft ! net
 Date: 2003-02-27 11:47:41
 [Download message RAW]

 [Attachment #2 (multipart/alternative)]


 BlankHi,
 I am trying to use logic tags to find if the value is present in my
 formbean attribute,
 depending on if value is present or not i have to take some action
 please check attached code for details.

  logic:empty name=wigadminwizardform
 property=sTransactionType
 html:text property=sTransactionType size=25
 maxlength=25/
 /logic:empty
 logic:notEmpty name=wigadminwizardform
 property=sTransactionType
  bean:write name=wigadminwizardform
 property=sTransactionType/
 /logic:notEmpty

 wigadminwizardform is my formbean with session scope. above the code i
have
 put aline

 jsp:useBean id=wigadminwizardform scope=session
 class=wigadmin.struts.forms.WIGAdminWizardForm/

 so my page has a view for the bean.

 what is happening in, even if sTransationType is populated i am getting
text
 box.
 which should appear on page only if sTransactionType is empty.

 what can be the problem



 Regards
 Chetan

 -
 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]



Re: How to to a OR with logic tags

2002-11-13 Thread Charles
Thanks for the prompt reply Richard. I'll check out JSTL


- Original Message -
From: Richard Yee [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Tuesday, November 12, 2002 10:22 PM
Subject: Re: How to to a OR with logic tags


 Charles,
 I'd suggest checking out the conditional tags in the JSTL to do the OR
 operation rather than using the Struts logic tag. You will find that the
 JSTL expression capability and if, choose, when, and otherwise tags make
it
 easier to do complex logic than the struts conditional tags do.

 Regards,

 Richard

 At 11:01 AM 11/13/2002 -0800, you wrote:
 Hi I'm still quite new with Struts. I want to do a OR comparison using
the
 tags. Does anyone has any idea how this can be done? -- To unsubscribe,
 e-mail: For additional commands, e-mail:



 --
 To unsubscribe, e-mail:
mailto:struts-user-unsubscribe;jakarta.apache.org
 For additional commands, e-mail:
mailto:struts-user-help;jakarta.apache.org




--
To unsubscribe, e-mail:   mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:struts-user-help;jakarta.apache.org




How to to a OR with logic tags

2002-11-12 Thread Charles
Hi I'm still quite new with Struts. I want to do a OR comparison using the
html:logic tags. Does anyone has any idea how this can be done?



--
To unsubscribe, e-mail:   mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:struts-user-help;jakarta.apache.org




Re: How to to a OR with logic tags

2002-11-12 Thread Richard Yee
Charles,
I'd suggest checking out the conditional tags in the JSTL to do the OR 
operation rather than using the Struts logic tag. You will find that the 
JSTL expression capability and if, choose, when, and otherwise tags make it 
easier to do complex logic than the struts conditional tags do.

Regards,

Richard

At 11:01 AM 11/13/2002 -0800, you wrote:
Hi I'm still quite new with Struts. I want to do a OR comparison using the
tags. Does anyone has any idea how this can be done? -- To unsubscribe, 
e-mail: For additional commands, e-mail:



--
To unsubscribe, e-mail:   mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:struts-user-help;jakarta.apache.org




logic tags

2002-11-06 Thread Mohan Radhakrishnan
Hi,
 Our requirement is this. Based on the report chosen from the menu, we
have to show parameters. Parameters vary with the report chosen.

We have html:options tags to display the parameters. Are logic tags the
best approach to introduce if/else
logic inside the JSP to decide which parameters to show? Is there a better
approach ?
bye,
Mohan

--
To unsubscribe, e-mail:   mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:struts-user-help;jakarta.apache.org




[Nested Tags] Nested vs logic tags..

2002-10-28 Thread Jeff_Mychasiw
Greetings:
  I am almost exclusively using nested tags.
Every now and then I run  into a problem and have to switch over the
corresponding logic or bean version.

Can anyony tell me if this is a bug?  I am using 1.1b2

I tried this with nested:equal but got a NullPointerException (listed
below)
nested:iterate property=meshList indexId=listIndex
  tr
 td
 %-- Show this only for the first item--%
 nested:equal name=listIndex value=0

  /nested:equal


but had to change the equals to:
 logic:equal name=listIndex value=0

  /logic:equal


2002-10-28 09:52:49 jsp: init
2002-10-28 09:52:49 ApplicationDispatcher[/ar] Servlet.service() for servlet jsp threw 
exception
java.lang.NullPointerException
  at 
org.apache.struts.taglib.nested.NestedPropertyHelper.getNestedProperty(NestedPropertyHelper.java:173)
  at 
org.apache.struts.taglib.nested.NestedPropertyHelper.getNestedProperty(NestedPropertyHelper.java:195)
  at 
org.apache.struts.taglib.nested.NestedPropertyHelper.setNestedProperties(NestedPropertyHelper.java:242)
  at 
org.apache.struts.taglib.nested.logic.NestedEqualTag.doStartTag(NestedEqualTag.java:91)
  at 
org.apache.jsp.CustomerMeshMainForm$jsp._jspService(CustomerMeshMainForm$jsp.java:475)
  at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)


--
To unsubscribe, e-mail:   mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:struts-user-help;jakarta.apache.org




RE: [Nested Tags] Nested vs logic tags..

2002-10-28 Thread Taylor, Jason
Just a hunch-- have you tried specifying a 'name' for the nested:iterate
tag?  

-Original Message-
From: [EMAIL PROTECTED] [mailto:Jeff_Mychasiw;nlgroup.ca]
Sent: Monday, October 28, 2002 8:03 AM
To: [EMAIL PROTECTED]
Subject: [Nested Tags] Nested vs logic tags..


Greetings:
  I am almost exclusively using nested tags.
Every now and then I run  into a problem and have to switch over the
corresponding logic or bean version.

Can anyony tell me if this is a bug?  I am using 1.1b2

I tried this with nested:equal but got a NullPointerException (listed
below)
nested:iterate property=meshList indexId=listIndex
  tr
 td
 %-- Show this only for the first item--%
 nested:equal name=listIndex value=0

  /nested:equal


but had to change the equals to:
 logic:equal name=listIndex value=0

  /logic:equal


2002-10-28 09:52:49 jsp: init
2002-10-28 09:52:49 ApplicationDispatcher[/ar] Servlet.service() for servlet
jsp threw exception
java.lang.NullPointerException
  at
org.apache.struts.taglib.nested.NestedPropertyHelper.getNestedProperty(Neste
dPropertyHelper.java:173)
  at
org.apache.struts.taglib.nested.NestedPropertyHelper.getNestedProperty(Neste
dPropertyHelper.java:195)
  at
org.apache.struts.taglib.nested.NestedPropertyHelper.setNestedProperties(Nes
tedPropertyHelper.java:242)
  at
org.apache.struts.taglib.nested.logic.NestedEqualTag.doStartTag(NestedEqualT
ag.java:91)
  at
org.apache.jsp.CustomerMeshMainForm$jsp._jspService(CustomerMeshMainForm$jsp
.java:475)
  at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)


--
To unsubscribe, e-mail:
mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail:
mailto:struts-user-help;jakarta.apache.org



RE: [Nested Tags] Nested vs logic tags..

2002-10-28 Thread Jeff_Mychasiw

No I have not.
I could be wrong but I am under the assumptiion that  the name attribute is
used to look for a bean.

The documents state that the nested versions of the tags will work the same
but allow you exclude specific references to parent tags.
I have done this many times:
  logic:iterate name=myFormBean property=meshList id=myObject
indexId=listIndex type=com.nlg.ar.SomeVo
logic:equal name=listIndex value=0XXX/logic:iterate
bean:write name=myObject property=legalName /
  /logic:iterate

  I like the nested version..
  nested:iterate property=meshList indexId=listIndex 
nested:equal name=listIndex value=0XXX/nested:iterate
nested:write property=legalName /
  /nested:iterate

  It is not the end of the world, but I in order to use the indexId I have
 to use the logic:equal
  (note the equal tag)
  nested:iterate property=meshList indexId=listIndex 
logic:equal name=listIndex value=0XXX/logic:iterate
nested:write property=legalName /
  /nested:iterate







Taylor, Jason [EMAIL PROTECTED] on 10/28/2002 02:38:33 PM

Please respond to Struts Users Mailing List
   [EMAIL PROTECTED]

To:'Struts Users Mailing List' [EMAIL PROTECTED]
cc:

Subject:RE: [Nested Tags] Nested vs logic tags..


Just a hunch-- have you tried specifying a 'name' for the nested:iterate
tag?

-Original Message-
From: [EMAIL PROTECTED] [mailto:Jeff_Mychasiw;nlgroup.ca]
Sent: Monday, October 28, 2002 8:03 AM
To: [EMAIL PROTECTED]
Subject: [Nested Tags] Nested vs logic tags..


Greetings:
  I am almost exclusively using nested tags.
Every now and then I run  into a problem and have to switch over the
corresponding logic or bean version.

Can anyony tell me if this is a bug?  I am using 1.1b2

I tried this with nested:equal but got a NullPointerException (listed
below)
nested:iterate property=meshList indexId=listIndex
  tr
 td
 %-- Show this only for the first item--%
 nested:equal name=listIndex value=0

  /nested:equal


but had to change the equals to:
 logic:equal name=listIndex value=0

  /logic:equal


2002-10-28 09:52:49 jsp: init
2002-10-28 09:52:49 ApplicationDispatcher[/ar] Servlet.service() for
servlet
jsp threw exception
java.lang.NullPointerException
  at
org.apache.struts.taglib.nested.NestedPropertyHelper.getNestedProperty(Neste

dPropertyHelper.java:173)
  at
org.apache.struts.taglib.nested.NestedPropertyHelper.getNestedProperty(Neste

dPropertyHelper.java:195)
  at
org.apache.struts.taglib.nested.NestedPropertyHelper.setNestedProperties(Nes

tedPropertyHelper.java:242)
  at
org.apache.struts.taglib.nested.logic.NestedEqualTag.doStartTag(NestedEqualT

ag.java:91)
  at
org.apache.jsp.CustomerMeshMainForm$jsp.
_jspService(CustomerMeshMainForm$jsp
.java:475)
  at
  org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)


--
To unsubscribe, e-mail:
mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail:
mailto:struts-user-help;jakarta.apache.org








--
To unsubscribe, e-mail:   mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:struts-user-help;jakarta.apache.org




RE: [Nested Tags] Nested vs logic tags..

2002-10-28 Thread Arron Bates
 Just a hunch-- have you tried specifying a 'name' for the nested:iterate
 tag?  

The nested tags don't need it, and if it's provided they will ignore it.
Why?... because all the tags are working off the same bean structure,
and this is defined for us by the form tag. The nested tags will fetch
this bean. Because of this, all the nested tags within the form bean
don't need the name property to be set.


 From: [EMAIL PROTECTED] [mailto:Jeff_Mychasiw;nlgroup.ca]
 Greetings:
   I am almost exclusively using nested tags.
 Every now and then I run  into a problem and have to switch over the
 corresponding logic or bean version.
 
 Can anyony tell me if this is a bug?  I am using 1.1b2
 
 I tried this with nested:equal but got a NullPointerException (listed
 below)
 nested:iterate property=meshList indexId=listIndex
   tr
  td
  %-- Show this only for the first item--%
  nested:equal name=listIndex value=0
 
   /nested:equal

Try remove the name property (for reasons explained above), and try
aiming the property property at it.

It looks like you're trying to get the current object of the iterate
tag, so this may work...

nested:iterate property=meshList
  tr
td
  nested:equal property=this/ value=0
[...]
  /nested:equal
/td
  /tr
/nested:iterate


...the this/ or ./ simply refers to the current parent object level
just like using ./ on a command line. If it's not the current object
you're after, point the property at one of it's relative properties.

See if that works.


Arron.



--
To unsubscribe, e-mail:   mailto:struts-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:struts-user-help;jakarta.apache.org




Re: using OR condition with logic tags

2002-10-16 Thread chanoch

however, this is quite ugly - you end up having to write two outputs for
what is basically the same problem, hence the reference to OR.

That means maintaining two Stuff's which are identical

thoughts? (except for suggesting tiles which confused my designer guys
completely - they already are trying to work out why I am designing new
HTML elements)

chanoch


- Original Message -
From: Eddie Bush [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Tuesday, October 15, 2002 11:26 PM
Subject: Re: using OR condition with logic tags


 logic:equal name=foo value=1
 !-- Stuff for when foo == 1 --
 /logic:equal
 logic:equal name=foo value=2
 !-- Stuff for when foo == 2 --
 /logic:equal

 -- OR -- JSTL Approach 1

 c:choose
 c:when test=${foo == 1}
 !-- Stuff for when foo == 1 --
 /c:when
 c:when test=${foo == 2}
 !-- Stuff for when foo == 1 --
 /c:when
 /c:choose

 -- OR -- JSTL Approach 2

 c:choose
 c:when test=${foo == 1}
 !-- Stuff for when foo == 1 --
 /c:when
 c:otherwise
 !-- Stuff for when foo == 1 --
 /c:otherwise
 /c:choose

 Sukhenko, Mikhail (Contr) wrote:

 Hey, guys!
 Do any of you know how to set up an OR condition with logic:equal tags?
 i.e. :
 
 logic:equal name=foo value=1 OR logic:equal name=foo value=2
 
 Thanks
 

 --
 Eddie Bush




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


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




Re: using OR condition with logic tags

2002-10-16 Thread Eddie Bush

Oh --- OR --- I was thinking ELSE.  Sorry.

JSTL solution:

c:if test=${(foo == 1) || (foo == 2)}
!-- relevant code --
/c:if

The Struts-based solution would be the same as I mentioned before, I 
believe.  Sorry - I somehow understood you wanted an ELSE!

chanoch wrote:

however, this is quite ugly - you end up having to write two outputs for
what is basically the same problem, hence the reference to OR.

That means maintaining two Stuff's which are identical

thoughts? (except for suggesting tiles which confused my designer guys
completely - they already are trying to work out why I am designing new
HTML elements)

chanoch


-- 
Eddie Bush




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




using OR condition with logic tags

2002-10-16 Thread Sukhenko, Mikhail (Contr)

Hey, guys!
Do any of you know how to set up an OR condition with logic:equal tags?
i.e. :

logic:equal name=foo value=1 OR logic:equal name=foo value=2

Thanks


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




Re: using OR condition with logic tags

2002-10-16 Thread Craig R. McClanahan



On Wed, 16 Oct 2002, chanoch wrote:

 Date: Wed, 16 Oct 2002 20:10:47 +0100
 From: chanoch [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED]
 Subject: Re: using OR condition with logic tags

 however, this is quite ugly - you end up having to write two outputs for
 what is basically the same problem, hence the reference to OR.

 That means maintaining two Stuff's which are identical

 thoughts? (except for suggesting tiles which confused my designer guys
 completely - they already are trying to work out why I am designing new
 HTML elements)


Again using JSTL (Servlet 2.3 / JSP 1.2 container is required), you can
use the || operator to implement an OR:

  c:if test=${(foo == '1') || (foo == '2')}/
... stuff when foo is 1 or 2 ...
  /c:if

The expression language in JSTL 1.0 (and also in JSP 2.0, where you can
even use it in template text) is likely to become a JSP page author's best
friend.  But if you're stuck on a Servlet 2.2 / JSP 1.1 based server,
you're best bet is probably to write your own custom tag that implements
the test you are after.

 chanoch


Craig



 - Original Message -
 From: Eddie Bush [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED]
 Sent: Tuesday, October 15, 2002 11:26 PM
 Subject: Re: using OR condition with logic tags


  logic:equal name=foo value=1
  !-- Stuff for when foo == 1 --
  /logic:equal
  logic:equal name=foo value=2
  !-- Stuff for when foo == 2 --
  /logic:equal
 
  -- OR -- JSTL Approach 1
 
  c:choose
  c:when test=${foo == 1}
  !-- Stuff for when foo == 1 --
  /c:when
  c:when test=${foo == 2}
  !-- Stuff for when foo == 1 --
  /c:when
  /c:choose
 
  -- OR -- JSTL Approach 2
 
  c:choose
  c:when test=${foo == 1}
  !-- Stuff for when foo == 1 --
  /c:when
  c:otherwise
  !-- Stuff for when foo == 1 --
  /c:otherwise
  /c:choose
 
  Sukhenko, Mikhail (Contr) wrote:
 
  Hey, guys!
  Do any of you know how to set up an OR condition with logic:equal tags?
  i.e. :
  
  logic:equal name=foo value=1 OR logic:equal name=foo value=2
  
  Thanks
  
 
  --
  Eddie Bush
 
 
 
 
  --
  To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]


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




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




using OR condition with logic tags

2002-10-15 Thread Sukhenko, Mikhail (Contr)

Hey, guys!
Do any of you know how to set up an OR condition with logic:equal tags?
i.e. :

logic:equal name=foo value=1 OR logic:equal name=foo value=2

Thanks

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




Re: using OR condition with logic tags

2002-10-15 Thread Eddie Bush

logic:equal name=foo value=1
!-- Stuff for when foo == 1 --
/logic:equal
logic:equal name=foo value=2
!-- Stuff for when foo == 2 --
/logic:equal

-- OR -- JSTL Approach 1

c:choose
c:when test=${foo == 1}
!-- Stuff for when foo == 1 --
/c:when
c:when test=${foo == 2}
!-- Stuff for when foo == 1 --
/c:when
/c:choose

-- OR -- JSTL Approach 2

c:choose
c:when test=${foo == 1}
!-- Stuff for when foo == 1 --
/c:when
c:otherwise
!-- Stuff for when foo == 1 --
/c:otherwise
/c:choose

Sukhenko, Mikhail (Contr) wrote:

Hey, guys!
Do any of you know how to set up an OR condition with logic:equal tags?
i.e. :

logic:equal name=foo value=1 OR logic:equal name=foo value=2

Thanks


-- 
Eddie Bush




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




Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-10 Thread David Graham

Would it hurt for struts to follow the 2.3 .jar layout?  People using 2.3 
could benefit from reduced deployment hassles while others could continue 
using the old way.

Dave


From: Craig R. McClanahan [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???
Date: Wed, 9 Oct 2002 20:56:35 -0700 (PDT)



On Wed, 9 Oct 2002, David Graham wrote:

  Date: Wed, 09 Oct 2002 18:27:02 -0600
  From: David Graham [EMAIL PROTECTED]
  Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???
 
  Thanks for the info Craig.  I didn't know you didn't have to list them 
in
  the web.xml file and put the tlds in your app.  Does this apply to any
  taglib on a servlet 2.3 compliant container as long as you use the uri 
given
  in the tld?

Yes, this should work on any 2.3 container.  The secret recipie:

* The TLD (or TLDs, because you can have more than one tag library
   in the same JAR) has to be in the META-INF/tlds directory of a JAR
   inside the webapp, and have a *.tld extension.

* Each such TLD must include a uri element with the canonical URI
   by which this tag library is identified.

* These are the URIs you use in your %@ taglib % directives.

Note that JSP 1.1 (which is the minimum required platform for Struts)
allows a single TLD to be stored at /META-INF/taglib.tld, but that was
not sufficient for Struts since we have several such libraries.  Support
for auto-scanning JAR files was also very inconsistenty implemented in JSP
1.1 containers, so I've stuck with the original style for Struts 1.1
examples and documentation.  Once Struts formally adopts JSP 1.2 or later
as the minimum platform, we'll be able to change that.

 
  Also, I switched from bean:message to fmt:message but then realized 
that
  the struts tag will pick the appropriate subapp resources.  Is this the 
only
  difference from the jstl version?

There's actually somewhat more to it than that for I18N.  Most
importantly, the fmt:message tag and its friends work off of resource
bundles, not off of Struts MessageResources objects (although in practice,
since both can operate off the same properties files, this is not a huge
impediment).  In addition, you can dynamically establish the default
resource bundle (and/or locale) for i18n tags in a chunk of a page by
using fmt:setBundle, or in a couple of other ways -- see Section 8.2 of
the JSTL spec for details.

 
  I just thought it would be cool if containers recognized how cool struts 
is
  by optimizing the implementation of custom tags :-).  Big players like 
IBM
  are putting an increasing emphasis on struts

Indeed -- it was quite a rush for me to see an Add Struts Support button
in the latest editions of WSAD :-).  And they aren't the only ones ...

  so maybe in the future we'll
  see this.

Certainly this is a feasible thing to do.  In Tomcat land, one of the
original goals of writing Jasper2 was to enable plugins for things like
this, so it might someday be possible for Struts developers to create such
a plugin (Tomcat-specific, of course, but there's *lots* of Tomcat users).

On the other hand, I'm betting that the containers will go for optimized
support on JSTL (and JavaServer Faces when it's done) before they would
consider this.

   Although, considering how long it took them to release a 2.3
  compliant Websphere this may be wishful thinking.
 
  Dave

Craig


 
 
  From: Craig R. McClanahan [EMAIL PROTECTED]
  Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
  To: Struts Users Mailing List [EMAIL PROTECTED]
  Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???
  Date: Wed, 9 Oct 2002 15:02:00 -0700 (PDT)
  
  
  
  On Wed, 9 Oct 2002, David Graham wrote:
  
Date: Wed, 09 Oct 2002 13:54:32 -0600
From: David Graham [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: [OT] Re: Avoid Heavy Use of Logic Tags ???
   
I read somewhere that you should use http://java.sun.com/jstl/core 
for
  the
taglib uri in your web.xml file for the JSTL libraries (as opposed 
to
something you make up like jstl-core).  The author stated that using
  that
full uri would allow a container to optimize those tags like you
  mentioned.
   
  
  Each of the standard tag libraries in JSTl has a canonical URI, as 
defined
  in the JSTL Spec.  These are the URIs for the EL-based versions of the
  libraries (which is what you'd use in preference to the RT versions 
that
  do not recognize EL expressions):
  
  Core:   http://java.sun.com/jstl/core
  
  XML:http://java.sun.com/jstl/xml
  
  I18N  Formatting:  http://java.sun.com/jstl/fmt
  
  SQL:http://java.sun.com/jstl/sql
  
  It is by the use of these URIs that you specify you are talking about
  *the* standard tag libraries

Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-10 Thread Craig R. McClanahan



On Thu, 10 Oct 2002, David Graham wrote:

 Date: Thu, 10 Oct 2002 07:48:58 -0600
 From: David Graham [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

 Would it hurt for struts to follow the 2.3 .jar layout?  People using 2.3
 could benefit from reduced deployment hassles while others could continue
 using the old way.


Do you mean the META-INF/tlds directory?  That depends on whether your
container gracefully deals with the same tag library getting declared more
than once (from the implicit search of the JAR, and the explicit
declaration in the web.xml file of most Struts apps).

I cannot test this on every possible platform; therefore, making such a
change this late in the beta cycle seems like a high risk activity.  It's
certainly something to do for post-1.1 though.

 Dave

Craig


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




Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-10 Thread Kris Schneider

Doesn't Struts already support JSP 1.2 packaged tag libraries? For 1.0.2, the 
following are contained in MEATA-INF/tlds:

struts-bean.tld
struts-form.tld
struts-html.tld
struts-logic.tld
struts-template.tld

The taglib elements in those TLD files contain uri elements, so I simpy use 
something like this in my JSPs:

%@ taglib prefix=bean uri=http://jakarta.apache.org/struts/tags-bean-1.0.2; 
%

and I don't have to worry about pulling the TLD files out of the JAR or adding 
taglib elements to web.xml. I'm pretty sure it's the same for 1.1b2, except for 
a change to the value of the uri element. Maybe I missed the intent of the 
question...

Quoting Craig R. McClanahan [EMAIL PROTECTED]:

 
 
 On Thu, 10 Oct 2002, David Graham wrote:
 
  Date: Thu, 10 Oct 2002 07:48:58 -0600
  From: David Graham [EMAIL PROTECTED]
  Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???
 
  Would it hurt for struts to follow the 2.3 .jar layout?  People using 2.3
  could benefit from reduced deployment hassles while others could continue
  using the old way.
 
 
 Do you mean the META-INF/tlds directory?  That depends on whether your
 container gracefully deals with the same tag library getting declared more
 than once (from the implicit search of the JAR, and the explicit
 declaration in the web.xml file of most Struts apps).
 
 I cannot test this on every possible platform; therefore, making such a
 change this late in the beta cycle seems like a high risk activity.  It's
 certainly something to do for post-1.1 though.
 
  Dave
 
 Craig
 
 
 --
 To unsubscribe, e-mail:  
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 


-- 
Kris Schneider mailto:[EMAIL PROTECTED]
D.O.Tech   http://www.dotech.com/

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




Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-10 Thread Craig R. McClanahan



On Thu, 10 Oct 2002, Kris Schneider wrote:

 Date: Thu, 10 Oct 2002 12:39:08 -0400
 From: Kris Schneider [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED]
 Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

 Doesn't Struts already support JSP 1.2 packaged tag libraries? For 1.0.2, the
 following are contained in MEATA-INF/tlds:

 struts-bean.tld
 struts-form.tld
 struts-html.tld
 struts-logic.tld
 struts-template.tld

 The taglib elements in those TLD files contain uri elements, so I simpy use
 something like this in my JSPs:

 %@ taglib prefix=bean uri=http://jakarta.apache.org/struts/tags-bean-1.0.2;
 %

 and I don't have to worry about pulling the TLD files out of the JAR or adding
 taglib elements to web.xml. I'm pretty sure it's the same for 1.1b2, except for
 a change to the value of the uri element. Maybe I missed the intent of the
 question...


Yep ... you're right ... it is already there.  (Memo-to-self -- drink that
second cup of coffee before responding ... :-)

Craig

 Quoting Craig R. McClanahan [EMAIL PROTECTED]:

 
 
  On Thu, 10 Oct 2002, David Graham wrote:
 
   Date: Thu, 10 Oct 2002 07:48:58 -0600
   From: David Graham [EMAIL PROTECTED]
   Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
   To: [EMAIL PROTECTED]
   Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???
  
   Would it hurt for struts to follow the 2.3 .jar layout?  People using 2.3
   could benefit from reduced deployment hassles while others could continue
   using the old way.
  
 
  Do you mean the META-INF/tlds directory?  That depends on whether your
  container gracefully deals with the same tag library getting declared more
  than once (from the implicit search of the JAR, and the explicit
  declaration in the web.xml file of most Struts apps).
 
  I cannot test this on every possible platform; therefore, making such a
  change this late in the beta cycle seems like a high risk activity.  It's
  certainly something to do for post-1.1 though.
 
   Dave
 
  Craig
 
 
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
 
 


 --
 Kris Schneider mailto:[EMAIL PROTECTED]
 D.O.Tech   http://www.dotech.com/

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




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




Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread Johannes Carlén

Hi, I read Designing Enterprise Applications, Second
Edition Singh et al. Section 4.2.6.6 has the header
Avoid Heavy Use of Logic Tags and also writes Using
custom tags for logic provides little benefit, and
violates separation of logic and presentation. and
states that JSP-pages written in XML-syntax are at
least as difficult to maintain as other types.

In my experience, I find that these pages becomes a
lot more readable than pages coded using scriptlets.
Regarding the violation of logic and presentation -
you will have to do it somewhere in your presentation
tier...

Opinions on this? Anyone?

/Johannes


_
Gratis e-mail resten av livet på www.yahoo.se/mail
Busenkelt!

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




RE: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread Buchwald, Dave (PLC, IT, Tri-Com Consulting)

I agree...while looking back at some of my earlier JSPs, following the logic
of those large and cumbersome scriptlets is nearly impossible.  The succinct
nature of struts (or any) tags do make the JSP more readable as long as
you give the beans and properties functional names (common programming
sense).  
The JSP should only contain presentation markup and the custom tags that
facilitate 
that presentation (and maybe some optional javascript).


-Original Message-
From: Johannes Carlén [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 09, 2002 6:42 AM
To: [EMAIL PROTECTED]
Subject: Avoid Heavy Use of Logic Tags ???


Hi, I read Designing Enterprise Applications, Second
Edition Singh et al. Section 4.2.6.6 has the header
Avoid Heavy Use of Logic Tags and also writes Using
custom tags for logic provides little benefit, and
violates separation of logic and presentation. and
states that JSP-pages written in XML-syntax are at
least as difficult to maintain as other types.

In my experience, I find that these pages becomes a
lot more readable than pages coded using scriptlets.
Regarding the violation of logic and presentation -
you will have to do it somewhere in your presentation
tier...

Opinions on this? Anyone?

/Johannes


_
Gratis e-mail resten av livet på www.yahoo.se/mail
Busenkelt!

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


This communication, including attachments, is for the exclusive use of 
addressee and may contain proprietary, confidential or privileged 
information. If you are not the intended recipient, any use, copying, 
disclosure, dissemination or distribution is strictly prohibited. If 
you are not the intended recipient, please notify the sender 
immediately by return email and delete this communication and destroy all copies.


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




Re: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread David Graham

I think the author is referring to custom tags that perform business logic 
instead of presentation helpers.  The struts and most of the jstl tags are 
presentation.  Generally, business logic goes in java classes not custom 
tags (yes, custom tags are java classes but you get what I mean :-).

David


From: Johannes Carlén [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Avoid Heavy Use of Logic Tags ???
Date: Wed, 9 Oct 2002 12:41:34 +0200 (CEST)

Hi, I read Designing Enterprise Applications, Second
Edition Singh et al. Section 4.2.6.6 has the header
Avoid Heavy Use of Logic Tags and also writes Using
custom tags for logic provides little benefit, and
violates separation of logic and presentation. and
states that JSP-pages written in XML-syntax are at
least as difficult to maintain as other types.

In my experience, I find that these pages becomes a
lot more readable than pages coded using scriptlets.
Regarding the violation of logic and presentation -
you will have to do it somewhere in your presentation
tier...

Opinions on this? Anyone?

/Johannes


_
Gratis e-mail resten av livet på www.yahoo.se/mail
Busenkelt!

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




_
Chat with friends online, try MSN Messenger: http://messenger.msn.com


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




RE: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread Robert

I think that statement Using custom tags for logic provides little
benefit... is bit vague. I would say that custom tags the do
PRESENTATION logic are of benefit, e.g. iterators, formatting, html
controls, etc. all fit into that category for me. You are right, you
have to do it somehow, where otherwise you end up with just static HTML
right?

I'm not sure why he would say that XML syntax is more difficult to
maintain than other types. That is probably more of an 'eye of the
beholder' issue. If you have web developers that are unfamiliar with
Java, then the XML syntax is probably easier than a bunch of scriptlets,
no? Personally I think it is a lot easier to read than other dynamic
page systems (ASP, PHP, etc.), but that is just me.

- Robert

-Original Message-
From: Johannes Carlén [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, October 09, 2002 5:42 AM
To: [EMAIL PROTECTED]
Subject: Avoid Heavy Use of Logic Tags ???

Hi, I read Designing Enterprise Applications, Second
Edition Singh et al. Section 4.2.6.6 has the header
Avoid Heavy Use of Logic Tags and also writes Using
custom tags for logic provides little benefit, and
violates separation of logic and presentation. and
states that JSP-pages written in XML-syntax are at
least as difficult to maintain as other types.

In my experience, I find that these pages becomes a
lot more readable than pages coded using scriptlets.
Regarding the violation of logic and presentation -
you will have to do it somewhere in your presentation
tier...

Opinions on this? Anyone?

/Johannes


_
Gratis e-mail resten av livet på www.yahoo.se/mail
Busenkelt!

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



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




Re: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread Eddie Bush

... and now that we have the JSTL you can have your tags optimized into 
actual code.  It's my understanding, for example, that a forEach tag 
would be translated into an actual while (or was it for ...  anyway, you 
get the point).  So, you're bypassing the tag-usage overhead some.

Hopefully Martin will see this and elaborate (and correct me if I'm 
wrong).  I believe that's fairly close though ...

Of course - not all of us are on containers that even support the JSTL 
... but some of us are :-)

Robert wrote:

I think that statement Using custom tags for logic provides little
benefit... is bit vague. I would say that custom tags the do
PRESENTATION logic are of benefit, e.g. iterators, formatting, html
controls, etc. all fit into that category for me. You are right, you
have to do it somehow, where otherwise you end up with just static HTML
right?

I'm not sure why he would say that XML syntax is more difficult to
maintain than other types. That is probably more of an 'eye of the
beholder' issue. If you have web developers that are unfamiliar with
Java, then the XML syntax is probably easier than a bunch of scriptlets,
no? Personally I think it is a lot easier to read than other dynamic
page systems (ASP, PHP, etc.), but that is just me.

- Robert

-- 
Eddie Bush




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




[OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread David Graham

I read somewhere that you should use http://java.sun.com/jstl/core for the 
taglib uri in your web.xml file for the JSTL libraries (as opposed to 
something you make up like jstl-core).  The author stated that using that 
full uri would allow a container to optimize those tags like you mentioned.

First, is that true?  Second, it would be neat if containers optimized 
Struts tags in a similar manner.  Maybe the Tomcat team would be willing to 
do this since they're both on jakarta.

Dave


From: Eddie Bush [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: Re: Avoid Heavy Use of Logic Tags ???
Date: Wed, 09 Oct 2002 12:25:08 -0500

... and now that we have the JSTL you can have your tags optimized into 
actual code.  It's my understanding, for example, that a forEach tag would 
be translated into an actual while (or was it for ...  anyway, you get the 
point).  So, you're bypassing the tag-usage overhead some.

Hopefully Martin will see this and elaborate (and correct me if I'm wrong). 
  I believe that's fairly close though ...

Of course - not all of us are on containers that even support the JSTL ... 
but some of us are :-)

Robert wrote:

I think that statement Using custom tags for logic provides little
benefit... is bit vague. I would say that custom tags the do
PRESENTATION logic are of benefit, e.g. iterators, formatting, html
controls, etc. all fit into that category for me. You are right, you
have to do it somehow, where otherwise you end up with just static HTML
right?

I'm not sure why he would say that XML syntax is more difficult to
maintain than other types. That is probably more of an 'eye of the
beholder' issue. If you have web developers that are unfamiliar with
Java, then the XML syntax is probably easier than a bunch of scriptlets,
no? Personally I think it is a lot easier to read than other dynamic
page systems (ASP, PHP, etc.), but that is just me.

- Robert

--
Eddie Bush




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




_
Chat with friends online, try MSN Messenger: http://messenger.msn.com


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




Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread Craig R. McClanahan



On Wed, 9 Oct 2002, David Graham wrote:

 Date: Wed, 09 Oct 2002 13:54:32 -0600
 From: David Graham [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Subject: [OT] Re: Avoid Heavy Use of Logic Tags ???

 I read somewhere that you should use http://java.sun.com/jstl/core for the
 taglib uri in your web.xml file for the JSTL libraries (as opposed to
 something you make up like jstl-core).  The author stated that using that
 full uri would allow a container to optimize those tags like you mentioned.


Each of the standard tag libraries in JSTl has a canonical URI, as defined
in the JSTL Spec.  These are the URIs for the EL-based versions of the
libraries (which is what you'd use in preference to the RT versions that
do not recognize EL expressions):

Core:   http://java.sun.com/jstl/core

XML:http://java.sun.com/jstl/xml

I18N  Formatting:  http://java.sun.com/jstl/fmt

SQL:http://java.sun.com/jstl/sql

It is by the use of these URIs that you specify you are talking about
*the* standard tag libraries.  This is true whether or not your container
has built in optimized support for JSTL or not.

NOTE:  If you use the JSTL RI (or the Apache version of it, the standard
tag library from jakarta-taglibs), you'll note that you don't have to
separatel copy the TLDs into your WEB-INF directory as is conventional for
Struts apps.  That's because they are included in the META-INF directory
of the JAR file (supported under Servlet 2.3/JSP 1.2 containers).  You
also don't have to explicitly list these TLDs in your web.xml file -- just
drop the appropriate JARs into /WEB-INF/lib and start using JSTL tags in
your pages.

 First, is that true?  Second, it would be neat if containers optimized
 Struts tags in a similar manner.  Maybe the Tomcat team would be willing to
 do this since they're both on jakarta.


Containers have the *opportunity* to provide optimized support for JSTL
tags, and I understand that Resin does this already.  But you can use an
implementation of the JSTL tags on any container, just like any other tag
library, by including it in your app.

As cool as Struts tags are :-), any container developer (including those
building Tomcat) are going to get a lot more bang for the buck by
supporting the standard tag libraries first.  That's one of the main
reasons that I encourage people to migrate to JSTL instead of the
struts-bean and struts-logic equivalents, along with the fact that the
expression language makes these tags substantially more powerful.  For
example, think of what you'd have to do to make this work with the Struts
tags:

  c:if test=${(cust.status == 'OPEN') || (cust.status == 'ONHOLD')}
Customer account is either open or on credit hold
  /c:if

And in JSP 2.0, you'll be able to use EL expressions anywhere in your
template text, not just in the attribute values of tags that understand
it.  Learning the EL syntax now will give you a head start on the future.

 Dave


Craig


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




Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread David Graham

Thanks for the info Craig.  I didn't know you didn't have to list them in 
the web.xml file and put the tlds in your app.  Does this apply to any 
taglib on a servlet 2.3 compliant container as long as you use the uri given 
in the tld?

Also, I switched from bean:message to fmt:message but then realized that 
the struts tag will pick the appropriate subapp resources.  Is this the only 
difference from the jstl version?

I just thought it would be cool if containers recognized how cool struts is 
by optimizing the implementation of custom tags :-).  Big players like IBM 
are putting an increasing emphasis on struts so maybe in the future we'll 
see this.  Although, considering how long it took them to release a 2.3 
compliant Websphere this may be wishful thinking.

Dave


From: Craig R. McClanahan [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???
Date: Wed, 9 Oct 2002 15:02:00 -0700 (PDT)



On Wed, 9 Oct 2002, David Graham wrote:

  Date: Wed, 09 Oct 2002 13:54:32 -0600
  From: David Graham [EMAIL PROTECTED]
  Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Subject: [OT] Re: Avoid Heavy Use of Logic Tags ???
 
  I read somewhere that you should use http://java.sun.com/jstl/core for 
the
  taglib uri in your web.xml file for the JSTL libraries (as opposed to
  something you make up like jstl-core).  The author stated that using 
that
  full uri would allow a container to optimize those tags like you 
mentioned.
 

Each of the standard tag libraries in JSTl has a canonical URI, as defined
in the JSTL Spec.  These are the URIs for the EL-based versions of the
libraries (which is what you'd use in preference to the RT versions that
do not recognize EL expressions):

Core:   http://java.sun.com/jstl/core

XML:http://java.sun.com/jstl/xml

I18N  Formatting:  http://java.sun.com/jstl/fmt

SQL:http://java.sun.com/jstl/sql

It is by the use of these URIs that you specify you are talking about
*the* standard tag libraries.  This is true whether or not your container
has built in optimized support for JSTL or not.

NOTE:  If you use the JSTL RI (or the Apache version of it, the standard
tag library from jakarta-taglibs), you'll note that you don't have to
separatel copy the TLDs into your WEB-INF directory as is conventional for
Struts apps.  That's because they are included in the META-INF directory
of the JAR file (supported under Servlet 2.3/JSP 1.2 containers).  You
also don't have to explicitly list these TLDs in your web.xml file -- just
drop the appropriate JARs into /WEB-INF/lib and start using JSTL tags in
your pages.

  First, is that true?  Second, it would be neat if containers optimized
  Struts tags in a similar manner.  Maybe the Tomcat team would be willing 
to
  do this since they're both on jakarta.
 

Containers have the *opportunity* to provide optimized support for JSTL
tags, and I understand that Resin does this already.  But you can use an
implementation of the JSTL tags on any container, just like any other tag
library, by including it in your app.

As cool as Struts tags are :-), any container developer (including those
building Tomcat) are going to get a lot more bang for the buck by
supporting the standard tag libraries first.  That's one of the main
reasons that I encourage people to migrate to JSTL instead of the
struts-bean and struts-logic equivalents, along with the fact that the
expression language makes these tags substantially more powerful.  For
example, think of what you'd have to do to make this work with the Struts
tags:

   c:if test=${(cust.status == 'OPEN') || (cust.status == 'ONHOLD')}
 Customer account is either open or on credit hold
   /c:if

And in JSP 2.0, you'll be able to use EL expressions anywhere in your
template text, not just in the attribute values of tags that understand
it.  Learning the EL syntax now will give you a head start on the future.

  Dave
 

Craig


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




_
Chat with friends online, try MSN Messenger: http://messenger.msn.com


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




Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread Kris Schneider

Sure, as in:

%@ taglib prefix=bean
uri=http://jakarta.apache.org/struts/tags-bean-1.0.2; %
%@ taglib prefix=html
uri=http://jakarta.apache.org/struts/tags-html-1.0.2; %

David Graham wrote:
 
 Thanks for the info Craig.  I didn't know you didn't have to list them in
 the web.xml file and put the tlds in your app.  Does this apply to any
 taglib on a servlet 2.3 compliant container as long as you use the uri given
 in the tld?
 
 Also, I switched from bean:message to fmt:message but then realized that
 the struts tag will pick the appropriate subapp resources.  Is this the only
 difference from the jstl version?
 
 I just thought it would be cool if containers recognized how cool struts is
 by optimizing the implementation of custom tags :-).  Big players like IBM
 are putting an increasing emphasis on struts so maybe in the future we'll
 see this.  Although, considering how long it took them to release a 2.3
 compliant Websphere this may be wishful thinking.
 
 Dave

-- 
Kris Schneider mailto:[EMAIL PROTECTED]
D.O.Tech   http://www.dotech.com/


smime.p7s
Description: S/MIME Cryptographic Signature


Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

2002-10-09 Thread Craig R. McClanahan



On Wed, 9 Oct 2002, David Graham wrote:

 Date: Wed, 09 Oct 2002 18:27:02 -0600
 From: David Graham [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???

 Thanks for the info Craig.  I didn't know you didn't have to list them in
 the web.xml file and put the tlds in your app.  Does this apply to any
 taglib on a servlet 2.3 compliant container as long as you use the uri given
 in the tld?

Yes, this should work on any 2.3 container.  The secret recipie:

* The TLD (or TLDs, because you can have more than one tag library
  in the same JAR) has to be in the META-INF/tlds directory of a JAR
  inside the webapp, and have a *.tld extension.

* Each such TLD must include a uri element with the canonical URI
  by which this tag library is identified.

* These are the URIs you use in your %@ taglib % directives.

Note that JSP 1.1 (which is the minimum required platform for Struts)
allows a single TLD to be stored at /META-INF/taglib.tld, but that was
not sufficient for Struts since we have several such libraries.  Support
for auto-scanning JAR files was also very inconsistenty implemented in JSP
1.1 containers, so I've stuck with the original style for Struts 1.1
examples and documentation.  Once Struts formally adopts JSP 1.2 or later
as the minimum platform, we'll be able to change that.


 Also, I switched from bean:message to fmt:message but then realized that
 the struts tag will pick the appropriate subapp resources.  Is this the only
 difference from the jstl version?

There's actually somewhat more to it than that for I18N.  Most
importantly, the fmt:message tag and its friends work off of resource
bundles, not off of Struts MessageResources objects (although in practice,
since both can operate off the same properties files, this is not a huge
impediment).  In addition, you can dynamically establish the default
resource bundle (and/or locale) for i18n tags in a chunk of a page by
using fmt:setBundle, or in a couple of other ways -- see Section 8.2 of
the JSTL spec for details.


 I just thought it would be cool if containers recognized how cool struts is
 by optimizing the implementation of custom tags :-).  Big players like IBM
 are putting an increasing emphasis on struts

Indeed -- it was quite a rush for me to see an Add Struts Support button
in the latest editions of WSAD :-).  And they aren't the only ones ...

 so maybe in the future we'll
 see this.

Certainly this is a feasible thing to do.  In Tomcat land, one of the
original goals of writing Jasper2 was to enable plugins for things like
this, so it might someday be possible for Struts developers to create such
a plugin (Tomcat-specific, of course, but there's *lots* of Tomcat users).

On the other hand, I'm betting that the containers will go for optimized
support on JSTL (and JavaServer Faces when it's done) before they would
consider this.

  Although, considering how long it took them to release a 2.3
 compliant Websphere this may be wishful thinking.

 Dave

Craig




 From: Craig R. McClanahan [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED]
 Subject: Re: [OT] Re: Avoid Heavy Use of Logic Tags ???
 Date: Wed, 9 Oct 2002 15:02:00 -0700 (PDT)
 
 
 
 On Wed, 9 Oct 2002, David Graham wrote:
 
   Date: Wed, 09 Oct 2002 13:54:32 -0600
   From: David Graham [EMAIL PROTECTED]
   Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
   To: [EMAIL PROTECTED]
   Subject: [OT] Re: Avoid Heavy Use of Logic Tags ???
  
   I read somewhere that you should use http://java.sun.com/jstl/core for
 the
   taglib uri in your web.xml file for the JSTL libraries (as opposed to
   something you make up like jstl-core).  The author stated that using
 that
   full uri would allow a container to optimize those tags like you
 mentioned.
  
 
 Each of the standard tag libraries in JSTl has a canonical URI, as defined
 in the JSTL Spec.  These are the URIs for the EL-based versions of the
 libraries (which is what you'd use in preference to the RT versions that
 do not recognize EL expressions):
 
 Core:   http://java.sun.com/jstl/core
 
 XML:http://java.sun.com/jstl/xml
 
 I18N  Formatting:  http://java.sun.com/jstl/fmt
 
 SQL:http://java.sun.com/jstl/sql
 
 It is by the use of these URIs that you specify you are talking about
 *the* standard tag libraries.  This is true whether or not your container
 has built in optimized support for JSTL or not.
 
 NOTE:  If you use the JSTL RI (or the Apache version of it, the standard
 tag library from jakarta-taglibs), you'll note that you don't have to
 separatel copy the TLDs into your WEB-INF directory as is conventional for
 Struts apps.  That's because they are included in the META-INF directory
 of the JAR file (supported under Servlet 2.3/JSP 1.2 containers).  You
 also don't have to explicitly list

/do/ being prepended to paths inside logic tags

2002-04-16 Thread rob

I've been using the struts logic tags to determine whether or not an img 
tag should be placed.

I have the following

logic:equal name=foo property=bar value=val
   img src=images/foo.jpg
/logic:equal

The page source shows the following
   img src=images/foo.jpg

However my log files say the following is being requested.

   /context/do/images/foo.jpg

As a result the images aren't loaded on my pages.  So i modified the img 
tag path to compensate.

   img src=../images/foo.jpg

This works but it's kind of dirty, is there a way around this?

Thanks.

Rob


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




RE: /do/ being prepended to paths inside logic tags

2002-04-16 Thread John Reid

 I have the following
 
 logic:equal name=foo property=bar value=val
img src=images/foo.jpg
 /logic:equal
 
 The page source shows the following
img src=images/foo.jpg
 
 However my log files say the following is being requested.
 
/context/do/images/foo.jpg
 
 As a result the images aren't loaded on my pages.  So i modified the img 
 tag path to compensate.
 
img src=../images/foo.jpg
 

try
html:img page=path/to/image/

John Reid

OpenConnect (Ireland) Ltd
+44 (0)2893 329 321
www.openconnect.co.uk 
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.349 / Virus Database: 195 - Release Date: 15/04/2002


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




logic-tags related to beans not derived from ActionForm?

2002-04-15 Thread @Basebeans.com

Subject: logic-tags related to beans not derived from ActionForm?
From: Johannes Wolfgang Woger [EMAIL PROTECTED]
 ===
Hallo,
I need logic:equal/present etc. etc  in my application
to make them more dynamic depending on the permissions of a user. The
information for these tags
should not appear in the ActionForm object. Is here
a possibility to fuel these tags with data from an other class, not derived
from ActionForm?

Thank in advance
Wolfgang



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




RE: logic-tags related to beans not derived from ActionForm?

2002-04-15 Thread Maris Orbidans


Yes, of course, it's possible.  There is no requirement that class you work with must 
be derived from ActionForm.
A class derived from ActionForm is a bean.

Logic tags also can work with cookies, request headers etc.   ( see doc. of logic tags 
)

I'd suggest you to create some JavaBean ( in session or request scope ) that contains 
info about user permissions  and access it from JSP.

Maris







equal - Evaluate the nested body content of this tag if the requested variable is 
equal to the specified value.  
Compares the variable specified by one of the selector attributes against the 
specified constant value. The nested body content of this tag is evaluated if the 
variable and value are equal. 

 
Attribute Name  Description 
 

cookie  The variable to be compared is the value of the cookie whose name is 
specified by this attribute.


header  The variable to be compared is the value of the header whose name is 
specified by this attribute. The name match is performed in a case insensitive manner.


nameThe variable to be compared is the JSP bean specified by this 
attribute, if property is not specified, or the value of the specified property of 
this bean, if property is specified.


parameter   The variable to be compared is the first, or only, value of the 
request parameter specified by this attribute.




 -Original Message-
 From: Struts Newsgroup (@Basebeans.com) [mailto:[EMAIL PROTECTED]]
 Sent: Monday, April 15, 2002 1:25 PM
 To: [EMAIL PROTECTED]
 Subject: logic-tags related to beans not derived from ActionForm?
 
 
 Subject: logic-tags related to beans not derived from ActionForm?
 From: Johannes Wolfgang Woger [EMAIL PROTECTED]
  ===
 Hallo,
 I need logic:equal/present etc. etc  in my application
 to make them more dynamic depending on the permissions of a user. The
 information for these tags
 should not appear in the ActionForm object. Is here
 a possibility to fuel these tags with data from an other 
 class, not derived
 from ActionForm?
 
 Thank in advance
 Wolfgang
 
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 
 

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




Re: logic-tags related to beans not derived from ActionForm?

2002-04-15 Thread Johannes Wolfgang Woger

Thank you Maris,
exactly what I needed. I suppose that is the way to
overcome the restriction that an Action can have only one
ActionForm.

Wolfgang


- Original Message -
From: Maris Orbidans [EMAIL PROTECTED]
Newsgroups: Struts
Sent: Monday, April 15, 2002 1:29 PM
Subject: RE: logic-tags related to beans not derived from ActionForm?



 Yes, of course, it's possible.  There is no requirement that class you
work with must be derived from ActionForm.
 A class derived from ActionForm is a bean.

 Logic tags also can work with cookies, request headers etc.   ( see doc.
of logic tags )

 I'd suggest you to create some JavaBean ( in session or request scope )
that contains info about user permissions  and access it from JSP.

 Maris







 equal - Evaluate the nested body content of this tag if the requested
variable is equal to the specified value.
 Compares the variable specified by one of the selector attributes against
the specified constant value. The nested body content of this tag is
evaluated if the variable and value are equal.


 Attribute Name Description


 cookie The variable to be compared is the value of the cookie whose name
is specified by this attribute.


 header The variable to be compared is the value of the header whose name
is specified by this attribute. The name match is performed in a case
insensitive manner.


 name The variable to be compared is the JSP bean specified by this
attribute, if property is not specified, or the value of the specified
property of this bean, if property is specified.


 parameter The variable to be compared is the first, or only, value of the
request parameter specified by this attribute.




  -Original Message-
  From: Struts Newsgroup (@Basebeans.com) [mailto:[EMAIL PROTECTED]]
  Sent: Monday, April 15, 2002 1:25 PM
  To: [EMAIL PROTECTED]
  Subject: logic-tags related to beans not derived from ActionForm?
 
 
  Subject: logic-tags related to beans not derived from ActionForm?
  From: Johannes Wolfgang Woger [EMAIL PROTECTED]
   ===
  Hallo,
  I need logic:equal/present etc. etc  in my application
  to make them more dynamic depending on the permissions of a user. The
  information for these tags
  should not appear in the ActionForm object. Is here
  a possibility to fuel these tags with data from an other
  class, not derived
  from ActionForm?
 
  Thank in advance
  Wolfgang
 
 
 
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
 
 

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



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




Re: logic-tags related to beans not derived from ActionForm?

2002-04-15 Thread Johannes Wolfgang Woger

Thanks,
missing comercial support is often a argument against
open source software , some decition maker think that
way. They should have visited this wonderfull newsgroup

Wolfgang
- Original Message -
From: Maris Orbidans [EMAIL PROTECTED]
Newsgroups: Struts
Sent: Monday, April 15, 2002 2:56 PM
Subject: RE: logic-tags related to beans not derived from ActionForm?



  Thank you Maris,
  exactly what I needed. I suppose that is the way to
  overcome the restriction that an Action can have only one
  ActionForm.

 Yes.

 BTW  You can add properties to you form bean, that don't correspond to
HTML input fields.

 For example a field that determines that input fields are read only.

 // Action class...
  form.setReadOnly(false);

 // JSP

 logic:notEqual name=Lim1vkontrole property=readOnly value=false 
 html:text property=datums readonly=true size=10
styleId=text maxlength=10/
 /logic:notEqual
 logic:equal name=Lim1vkontrole property=readOnly value=false 
 html:text property=datums size=10 styleId=text
maxlength=10/
 /logic:equal



 Maris

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



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




using logic tags and ApplicationResources values

2002-01-24 Thread McClung, Brian

I have a need to validate whether a Resource has a value associated with it.
I was hoping to use the logic:messagesPresent tag but it I can't seem to
get it to read from the bean:message tags.  How do I nest the
bean:message tag into another tag set so that the returned value of the
tag is treated as a string?

Thanks,

Brian McClung
Belo Interactive
214-977-4083


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




RE: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-15 Thread Tom Klaasen (TeleRelay)

After 25 hours, you're entitled to send more information for us to try
to give help on ;-)
Full stacktrace, jsp and relevant java code...

I suppose the other taglibs do work?

tomK


 -Original Message-
 From: Collard, John [mailto:[EMAIL PROTECTED]] 
 Sent: maandag 14 januari 2002 20:46
 To: 'Struts Users Mailing List'
 Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...
 
 
 Spent about 25 hours attempting to get it to work.  Kept 
 getting the no
 getter method found error, even though I must have compared 
 my code to the
 examples 60-70 times. Sorry.
 
 
  John Collard
  Senior Systems Analyst
  UtiliCorp United Information Technology
  7101 Mercy Road, Suite 400
  Omaha, NE  68106
  voice: 402-926-5236
  fax: 402-996-9736 
  email: [EMAIL PROTECTED]
  
  
 
 
 -Original Message-
 From: Tom Klaasen (TeleRelay) [mailto:[EMAIL PROTECTED]]
 Sent: Monday, January 14, 2002 4:23 AM
 To: Struts Users Mailing List
 Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...
 
 
  -Original Message-
  From: Arron Bates [mailto:[EMAIL PROTECTED]] 
  Sent: vrijdag 11 januari 2002 3:01
  To: Struts Users Mailing List
  Subject: Nesting Beans/Iterators/Logic tags  whatever else...
 [...]
  If you have used the extension and found it useful, can you 
  please reply 
  to this mail to show others that people are using it, and 
 that it is 
  worth using 
 [...]
 
 You know I use it, and you know I love it :-)
 
 tomK
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 --
 To unsubscribe, e-mail:   
 mailto:struts-user- [EMAIL PROTECTED]
 For 
 additional commands, 
 e-mail: mailto:[EMAIL PROTECTED]
 
 

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




Help using Struts Logic tags.

2002-01-15 Thread VEDRE, RANAPRATAP REDDY

What is the best way to write the following scriptlet code using Logic Tags.

 I tried to do it with present and notEmpty but couldn't get it to work.

% if(session.getAttribute(KEY) != null){ %

   if(session.getAttribute(KEY).equals(True))
   {
 // Some HTML goes here.
   }

% } %

-Thanks 

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




RE: Help using Struts Logic tags.

2002-01-15 Thread Andrew B Forman

I've been using the session taglib
http://jakarta.apache.org/taglibs/doc/session-doc/intro.html

which would end up looking something like...

session:existsAttribute name=KEY value=true
 session:equalsAttribute name=KEY matchTrue value=true
// Some HTML goes here.
 /session:equalsAttribute
/session:existsAttribute

_\|/___
  generation-d development
  andrew b forman 

 -Original Message-
 From: VEDRE, RANAPRATAP REDDY [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, January 15, 2002 9:48 AM
 To: '[EMAIL PROTECTED]'
 Subject: Help using Struts Logic tags.
 
 
 What is the best way to write the following scriptlet code using 
 Logic Tags.
 
  I tried to do it with present and notEmpty but couldn't get it to work.
 
 % if(session.getAttribute(KEY) != null){ %
 
if(session.getAttribute(KEY).equals(True))
{
  // Some HTML goes here.
}
 
 % } %
 
 -Thanks 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 

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




RE: Help using Struts Logic tags.

2002-01-15 Thread Keith Bacon


logic:equal name=KEY scope=session value=True 
/logic:equal

not tested - done my best..watch the capitalisation!
K.


--- Andrew B Forman [EMAIL PROTECTED] wrote:
 I've been using the session taglib
 http://jakarta.apache.org/taglibs/doc/session-doc/intro.html
 
 which would end up looking something like...
 
 session:existsAttribute name=KEY value=true
  session:equalsAttribute name=KEY matchTrue value=true
   // Some HTML goes here.
  /session:equalsAttribute
 /session:existsAttribute
 
 _\|/___
   generation-d development
   andrew b forman 
 
  -Original Message-
  From: VEDRE, RANAPRATAP REDDY [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, January 15, 2002 9:48 AM
  To: '[EMAIL PROTECTED]'
  Subject: Help using Struts Logic tags.
  
  
  What is the best way to write the following scriptlet code using 
  Logic Tags.
  
   I tried to do it with present and notEmpty but couldn't get it to work.
  
  % if(session.getAttribute(KEY) != null){ %
  
 if(session.getAttribute(KEY).equals(True))
 {
   // Some HTML goes here.
 }
  
  % } %
  
  -Thanks 
  
  --
  To unsubscribe, e-mail:   
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail: 
  mailto:[EMAIL PROTECTED]
  
 
 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]
 


__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

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




RE: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-15 Thread Collard, John

I didn't intend to sound as negative as I did.  I do owe that-- working on
it.  I do like it and will at least use different parts of it.  There are
many applications for the tags use -- even out side the iterate process.

John Collard
[EMAIL PROTECTED]





-Original Message-
From: Tom Klaasen (TeleRelay) [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 15, 2002 6:54 AM
To: Struts Users Mailing List
Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...


After 25 hours, you're entitled to send more information for us to try
to give help on ;-)
Full stacktrace, jsp and relevant java code...

I suppose the other taglibs do work?

tomK


 -Original Message-
 From: Collard, John [mailto:[EMAIL PROTECTED]] 
 Sent: maandag 14 januari 2002 20:46
 To: 'Struts Users Mailing List'
 Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...
 
 
 Spent about 25 hours attempting to get it to work.  Kept 
 getting the no
 getter method found error, even though I must have compared 
 my code to the
 examples 60-70 times. Sorry.
 
 
  John Collard
  Senior Systems Analyst
  UtiliCorp United Information Technology
  7101 Mercy Road, Suite 400
  Omaha, NE  68106
  voice: 402-926-5236
  fax: 402-996-9736 
  email: [EMAIL PROTECTED]
  
  
 
 
 -Original Message-
 From: Tom Klaasen (TeleRelay) [mailto:[EMAIL PROTECTED]]
 Sent: Monday, January 14, 2002 4:23 AM
 To: Struts Users Mailing List
 Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...
 
 
  -Original Message-
  From: Arron Bates [mailto:[EMAIL PROTECTED]] 
  Sent: vrijdag 11 januari 2002 3:01
  To: Struts Users Mailing List
  Subject: Nesting Beans/Iterators/Logic tags  whatever else...
 [...]
  If you have used the extension and found it useful, can you 
  please reply 
  to this mail to show others that people are using it, and 
 that it is 
  worth using 
 [...]
 
 You know I use it, and you know I love it :-)
 
 tomK
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 --
 To unsubscribe, e-mail:   
 mailto:struts-user- [EMAIL PROTECTED]
 For 
 additional commands, 
 e-mail: mailto:[EMAIL PROTECTED]
 
 

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

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




Re: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-15 Thread Arron Bates

There are many applications for the tags use -- even out side the iterate process

Hell yes! :)

I suppose some people will just see it as a way past their nested iteration problems,
but it brings so much more. Among other things, it will clean your JSP's because the 
markup's reduced for those tags working off the default bean for the form/root tag. 
This is just one of the benefits.

The tags literally extend the original Struts tags so the do exactly the same things, 
but in an improved markup context. Fact is, I've seen so many people in this user 
group use nested beans (anyone using dot notation in their properties, is nesting), 
and they can manage that so much easier if they go to the nested context.

Personally, it's a kick in the a-- of those other templating engines. I haven't heard 
of people moving over to them because they offer a better OO approach to their markup. 
(this is a personal view however ;)


Arron.


The full spiel --==
http://www.keyboardmonkey.com/struts



Collard, John wrote:

I didn't intend to sound as negative as I did.  I do owe that-- working on
it.  I do like it and will at least use different parts of it.  There are
many applications for the tags use -- even out side the iterate process.

John Collard
[EMAIL PROTECTED]



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




RE: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-14 Thread Tom Klaasen (TeleRelay)

 -Original Message-
 From: Arron Bates [mailto:[EMAIL PROTECTED]] 
 Sent: vrijdag 11 januari 2002 3:01
 To: Struts Users Mailing List
 Subject: Nesting Beans/Iterators/Logic tags  whatever else...
[...]
 If you have used the extension and found it useful, can you 
 please reply 
 to this mail to show others that people are using it, and that it is 
 worth using 
[...]

You know I use it, and you know I love it :-)

tomK

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




RE: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-14 Thread Collard, John

Spent about 25 hours attempting to get it to work.  Kept getting the no
getter method found error, even though I must have compared my code to the
examples 60-70 times. Sorry.


 John Collard
 Senior Systems Analyst
 UtiliCorp United Information Technology
 7101 Mercy Road, Suite 400
 Omaha, NE  68106
 voice: 402-926-5236
 fax: 402-996-9736 
 email: [EMAIL PROTECTED]
 
 


-Original Message-
From: Tom Klaasen (TeleRelay) [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 14, 2002 4:23 AM
To: Struts Users Mailing List
Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...


 -Original Message-
 From: Arron Bates [mailto:[EMAIL PROTECTED]] 
 Sent: vrijdag 11 januari 2002 3:01
 To: Struts Users Mailing List
 Subject: Nesting Beans/Iterators/Logic tags  whatever else...
[...]
 If you have used the extension and found it useful, can you 
 please reply 
 to this mail to show others that people are using it, and that it is 
 worth using 
[...]

You know I use it, and you know I love it :-)

tomK

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

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




Re: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-14 Thread Arron Bates

I'm willing to help you out if you can jar up the code and JSP's you 
have issues with.


Arron.


Collard, John wrote:

Spent about 25 hours attempting to get it to work.  Kept getting the no
getter method found error, even though I must have compared my code to the
examples 60-70 times. Sorry.


John Collard
Senior Systems Analyst
UtiliCorp United Information Technology
7101 Mercy Road, Suite 400
Omaha, NE  68106
voice: 402-926-5236
fax: 402-996-9736 
email: [EMAIL PROTECTED]




-Original Message-
From: Tom Klaasen (TeleRelay) [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 14, 2002 4:23 AM
To: Struts Users Mailing List
Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...


-Original Message-
From: Arron Bates [mailto:[EMAIL PROTECTED]] 
Sent: vrijdag 11 januari 2002 3:01
To: Struts Users Mailing List
Subject: Nesting Beans/Iterators/Logic tags  whatever else...

[...]

If you have used the extension and found it useful, can you 
please reply 
to this mail to show others that people are using it, and that it is 
worth using 

[...]

You know I use it, and you know I love it :-)

tomK

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

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





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




RE: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-14 Thread Alex Paransky

You know, I just had the same problem.  I was trying to use STRUTS with
Orion server, and I was not .WARing my application.  I looked at the
example, and the only difference was that their application was a .WAR my
was not.  Once I have created a .WAR things started to work rather
magically.

I am pretty new to STRUTS, so I am not sure what was going on.

-AP_

-Original Message-
From: Arron Bates [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 14, 2002 2:37 PM
To: Struts Users Mailing List
Subject: Re: Nesting Beans/Iterators/Logic tags  whatever else...


I'm willing to help you out if you can jar up the code and JSP's you
have issues with.


Arron.


Collard, John wrote:

Spent about 25 hours attempting to get it to work.  Kept getting the no
getter method found error, even though I must have compared my code to the
examples 60-70 times. Sorry.


John Collard
Senior Systems Analyst
UtiliCorp United Information Technology
7101 Mercy Road, Suite 400
Omaha, NE  68106
voice: 402-926-5236
fax: 402-996-9736
email: [EMAIL PROTECTED]




-Original Message-
From: Tom Klaasen (TeleRelay) [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 14, 2002 4:23 AM
To: Struts Users Mailing List
Subject: RE: Nesting Beans/Iterators/Logic tags  whatever else...


-Original Message-
From: Arron Bates [mailto:[EMAIL PROTECTED]]
Sent: vrijdag 11 januari 2002 3:01
To: Struts Users Mailing List
Subject: Nesting Beans/Iterators/Logic tags  whatever else...

[...]

If you have used the extension and found it useful, can you
please reply
to this mail to show others that people are using it, and that it is
worth using

[...]

You know I use it, and you know I love it :-)

tomK

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

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





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


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




RE: Nesting Beans/Iterators/Logic tags whatever else...

2002-01-11 Thread Sobkowski, Andrej

Arron,

I use it and I like it :)

Andrej

 -Original Message-
 From: Arron Bates [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, January 10, 2002 9:01 PM
 To: Struts Users Mailing List
 Subject: Nesting Beans/Iterators/Logic tags  whatever else...
 
 
 
 Some people on this list have been helped out of nesting 
 iterate tags 
 within iterate by being referred to the Nesting Extension. 
 If you want 
 to nest iterate tags within iterate tags the extension is 
 still by far 
 the best way to go, but the extension can do so much more.
 
 The extension links together any tag which uses a property 
 property to 
 bring them to the nesting context. Logic tags, Form tags, and a few 
 bean tags. There are other options in the extension which 
 capitalise on 
 the nesting context.
 
 To help out with all this, I've built a more extensive 
 resources page ( 
 http://www.keyboardmonkey.com/struts ) which has...
 - Two part primer which will get you up to speed with 
 what it does 
 and why it does it.
 - Two part tutorial which will get you under way to building your 
 first nested application.
 - Page of advanced topics which will tell you of some of 
 the other 
 things possible with the extension.
 - Running examples
 - Downloads of the extension and examples
 - A few words on some why should I implement this issues.
 - A questions/feedback form
 
 For this information, go here...
 http://www.keyboardmonkey.com/struts
 
 This is just a general announcement of the extension to the 
 Struts user 
 community. Some people may have picked up on the link from 
 the resources 
 page, some may not. This is because I really wanted to get the primer 
 and initial tutorial built to help people ramp-up on what it 
 does, and 
 generally make the task easier on all of us (it also gives me 
 more docco 
 to refer too if people have problems using the extension).
 
 I'm trying to get it into Struts itself, and it seems very 
 likely that 
 it will. Your views on the extension will help this along, so use the 
 feedback form on the page above if you feel it belongs in Struts, or 
 even if it doesn't those opinions are valid also.
 
 No-one who has used the extension has come back with a bad 
 response, and 
 all have seen the compelling reasons as to why it's useful 
 (it sits on 
 the original tags, so at worst you can use it as you do the 
 current tags).
 
 If you have used the extension and found it useful, can you 
 please reply 
 to this mail to show others that people are using it, and that it is 
 worth using (I know there's plenty of you out there, I've 
 seen the hit 
 stats on my resource site :) . The more people using it, the 
 more likely 
 for a quick adoption into Struts itself.
 
 
 I'll personally help anyone having troubles, where time permits.
 Hope you'll give nesting a try. It really does bring that 
 next level of 
 ability to Struts JSP views.
 
 
 
 Arron.
 
 
 (theKM*)
 * I think, therefore, I nest
 
 
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 



Nesting Beans/Iterators/Logic tags whatever else...

2002-01-10 Thread Arron Bates


Some people on this list have been helped out of nesting iterate tags 
within iterate by being referred to the Nesting Extension. If you want 
to nest iterate tags within iterate tags the extension is still by far 
the best way to go, but the extension can do so much more.

The extension links together any tag which uses a property property to 
bring them to the nesting context. Logic tags, Form tags, and a few 
bean tags. There are other options in the extension which capitalise on 
the nesting context.

To help out with all this, I've built a more extensive resources page ( 
http://www.keyboardmonkey.com/struts ) which has...
- Two part primer which will get you up to speed with what it does 
and why it does it.
- Two part tutorial which will get you under way to building your 
first nested application.
- Page of advanced topics which will tell you of some of the other 
things possible with the extension.
- Running examples
- Downloads of the extension and examples
- A few words on some why should I implement this issues.
- A questions/feedback form

For this information, go here...
http://www.keyboardmonkey.com/struts

This is just a general announcement of the extension to the Struts user 
community. Some people may have picked up on the link from the resources 
page, some may not. This is because I really wanted to get the primer 
and initial tutorial built to help people ramp-up on what it does, and 
generally make the task easier on all of us (it also gives me more docco 
to refer too if people have problems using the extension).

I'm trying to get it into Struts itself, and it seems very likely that 
it will. Your views on the extension will help this along, so use the 
feedback form on the page above if you feel it belongs in Struts, or 
even if it doesn't those opinions are valid also.

No-one who has used the extension has come back with a bad response, and 
all have seen the compelling reasons as to why it's useful (it sits on 
the original tags, so at worst you can use it as you do the current tags).

If you have used the extension and found it useful, can you please reply 
to this mail to show others that people are using it, and that it is 
worth using (I know there's plenty of you out there, I've seen the hit 
stats on my resource site :) . The more people using it, the more likely 
for a quick adoption into Struts itself.


I'll personally help anyone having troubles, where time permits.
Hope you'll give nesting a try. It really does bring that next level of 
ability to Struts JSP views.



Arron.


(theKM*)
* I think, therefore, I nest




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




setting a default bean for logic tags

2001-12-05 Thread Mike Hoeffner


Is it possible to set a default bean for logic tags like it is for form tags
so that they don't have to be named in each logic tag?

If I don't specify the name in an html:text tag, the name from the
parent form and its corresponding action tag will be used.  For example, in
the below html:text tag, fooForm will be used as the name from the
parent form since the name is not specified.

 action path=/foo type=FooAction name=fooForm scope=session
input=/foo.jsp
 ...
 html:form action=/foo
html:text property=bar/
 /html:form

Is there a way to do this with logic tags?  I have lots of redundant logic
tags that need to use different beans, but since I have to have a different
value for the name on all of them, there's no clean way to reuse the JSP.

Thanks,
Mike


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




RE: setting a default bean for logic tags

2001-12-05 Thread Siggelkow, Bill

I believe that the name attribute can take a request-time expression that
you could
use for this purpose.

-Original Message-
From: Mike Hoeffner [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 05, 2001 2:49 PM
To: [EMAIL PROTECTED]
Subject: setting a default bean for logic tags



Is it possible to set a default bean for logic tags like it is for form tags
so that they don't have to be named in each logic tag?

If I don't specify the name in an html:text tag, the name from the
parent form and its corresponding action tag will be used.  For example, in
the below html:text tag, fooForm will be used as the name from the
parent form since the name is not specified.

 action path=/foo type=FooAction name=fooForm scope=session
input=/foo.jsp
 ...
 html:form action=/foo
html:text property=bar/
 /html:form

Is there a way to do this with logic tags?  I have lots of redundant logic
tags that need to use different beans, but since I have to have a different
value for the name on all of them, there's no clean way to reuse the JSP.

Thanks,
Mike


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

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




AND/OR with logic tags

2001-10-01 Thread Eric Rizzo

Sorry if this has already been asked/answered here - the mail archive doesn't 
let me search for AND OR.

Is there a way to have multiple conditional logic with the Struts logic taglib? 
  For example, IF (user is present) OR (visitor equals true).

TIA,
Eric
-- 
Eric Rizzo, Software Engineer
OpenNetwork Technologies
http://www.opennetwork.com
-
I embrace my personality flaws, for without them
I might have no personality at all.




RE: AND/OR with logic tags

2001-10-01 Thread Niall Pemberton

I have a set of tags based on If that includes AND/OR, which can be
downloaded from Ted husted's site (reference is shown under Contributor
Taglib on the strust site):

  http://jakarta.apache.org/struts/userGuide/resources.html
  http://husted.com/about/struts/logic-niallp.htm


However this was recently discussed on the Dev list and 9 out of 10
committers (well 3 actually - Craig McClanahan, Martin Cooper, Ted Husted)
preferred the JSPTL route than this.

I include links to that thread below:

http://www.mail-archive.com/struts-dev@jakarta.apache.org/msg02946.html
http://www.mail-archive.com/struts-dev@jakarta.apache.org/msg02947.html
http://www.mail-archive.com/struts-dev@jakarta.apache.org/msg02959.html
http://www.mail-archive.com/struts-dev@jakarta.apache.org/msg02960.html
http://www.mail-archive.com/struts-dev@jakarta.apache.org/msg02962.html


Niall

 -Original Message-
 From: Eric Rizzo [mailto:[EMAIL PROTECTED]]
 Sent: 01 October 2001 17:06
 To: [EMAIL PROTECTED]
 Subject: AND/OR with logic tags


 Sorry if this has already been asked/answered here - the mail
 archive doesn't
 let me search for AND OR.

 Is there a way to have multiple conditional logic with the Struts
 logic taglib?
   For example, IF (user is present) OR (visitor equals true).

 TIA,
   Eric
 --
 Eric Rizzo, Software Engineer
 OpenNetwork Technologies
 http://www.opennetwork.com
 -
 I embrace my personality flaws, for without them
 I might have no personality at all.





comparing two beans with logic tags

2001-09-06 Thread Paradis, André

Hi,

I know i can use logic:equals name=thebean property=id
value=constant to compare a bean's property to a constant, but how do
i compare two beans property for equality using tags?

Thanks

Andre Paradis



Logic Tags

2001-08-29 Thread Mike Bungay

I'm having some problems getting the Logic present tag to fire when I pass
it a request parameter.  



RE: Logic Tags

2001-08-29 Thread Assenza, Chris

Could you be more specific so we can help? :) 

Chris

Christopher Assenza
Phone:  412.201.6026
Fax: 412.201.6060
Email:  [EMAIL PROTECTED]
ACCESSDATA
Moving Your Business from Point A to Point e.SM
http://www.accessdc.com/



-Original Message-
From: Mike Bungay [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 10:32 AM
To: '[EMAIL PROTECTED]'
Subject: Logic Tags


I'm having some problems getting the Logic present tag to fire when I pass
it a request parameter.  



RE: Logic Tags

2001-08-29 Thread Mike Bungay

I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??



RE: Logic Tags

2001-08-29 Thread Roumen Ganeff

You should check with 

logic:present name=success scope=request

the parameter checks only for parameters set in the URL or by form fields

G.
-Original Message-
From: Mike Bungay [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 6:17 PM
To: '[EMAIL PROTECTED]'
Subject: RE: Logic Tags


I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??





AW: Logic Tags

2001-08-29 Thread juraj Lenharcik

did you have:

String message = blabla;
request.setAttribute(success, message);

in your actionBean?


-juraj

-Ursprüngliche Nachricht-
Von: Mike Bungay [mailto:[EMAIL PROTECTED]]
Gesendet: Mittwoch, 29. August 2001 17:17
An: '[EMAIL PROTECTED]'
Betreff: RE: Logic Tags


I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??



RE: Logic Tags

2001-08-29 Thread George, Carl

It is firing it's just false.  Parameter checks the url.  
try
logic:present name=success 
name - checks the session, not sure about the request, you page have to do:
logic:present name=success scope=request 
-Original Message-
From: Mike Bungay [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:17 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Logic Tags


I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??



RE: Logic Tags

2001-08-29 Thread Mike Bungay

Yes But i just passed in a string value not a variable because I don't
really care what the value is I just want to check that it's present

-Original Message-
From: juraj Lenharcik [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:32 AM
To: '[EMAIL PROTECTED]'
Subject: AW: Logic Tags


did you have:

String message = blabla;
request.setAttribute(success, message);

in your actionBean?


-juraj

-Ursprüngliche Nachricht-
Von: Mike Bungay [mailto:[EMAIL PROTECTED]]
Gesendet: Mittwoch, 29. August 2001 17:17
An: '[EMAIL PROTECTED]'
Betreff: RE: Logic Tags


I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??



RE: Logic Tags

2001-08-29 Thread Mike Bungay

The present tag is not firing at all.  I tried the scope=request but there
was no change.  THe tag still doesn't fire..

-Original Message-
From: George, Carl [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:34 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Logic Tags


It is firing it's just false.  Parameter checks the url.  
try
logic:present name=success 
name - checks the session, not sure about the request, you page have to do:
logic:present name=success scope=request 
-Original Message-
From: Mike Bungay [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:17 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Logic Tags


I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??



RE: Logic Tags

2001-08-29 Thread George, Carl

but did you change parameter to name?

-Original Message-
From: Mike Bungay [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:54 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Logic Tags


The present tag is not firing at all.  I tried the scope=request but there
was no change.  THe tag still doesn't fire..

-Original Message-
From: George, Carl [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:34 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Logic Tags


It is firing it's just false.  Parameter checks the url.  
try
logic:present name=success 
name - checks the session, not sure about the request, you page have to do:
logic:present name=success scope=request 
-Original Message-
From: Mike Bungay [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:17 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Logic Tags


I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??



AW: Logic Tags

2001-08-29 Thread juraj Lenharcik

do you have 
%@ taglib uri=/WEB-INF/struts-logic.tld prefix=logic %
in your jsp?



-Ursprüngliche Nachricht-
Von: Mike Bungay [mailto:[EMAIL PROTECTED]]
Gesendet: Mittwoch, 29. August 2001 17:52
An: '[EMAIL PROTECTED]'
Betreff: RE: Logic Tags


Yes But i just passed in a string value not a variable because I don't
really care what the value is I just want to check that it's present

-Original Message-
From: juraj Lenharcik [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 29, 2001 11:32 AM
To: '[EMAIL PROTECTED]'
Subject: AW: Logic Tags


did you have:

String message = blabla;
request.setAttribute(success, message);

in your actionBean?


-juraj

-Ursprüngliche Nachricht-
Von: Mike Bungay [mailto:[EMAIL PROTECTED]]
Gesendet: Mittwoch, 29. August 2001 17:17
An: '[EMAIL PROTECTED]'
Betreff: RE: Logic Tags


I am passing the success (request.setAttribute(success,yes);) parameter
back to the jsp but in the jsp when I try this code: 

logic:present parameter=success 
SCRIPT LANGUAGE=JavaScript  
window.open(welcome.jsp, popupPage, top=0,left=0,resizable=yes,
status=yes +   ,width= + screen.width +
,height= + screen.height);
/script
/logic:present

the present tag doesn't fire.  I can print the success attribute on the jsp
page so I am getting the parameter back to the page.  

What am I doing wrong??



  1   2   >