. :-)
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Monday, December 29, 2003 1:41 PM
To: Struts Users Mailing List
Subject: Re: Is there a way to prevent urls from being entered from
the
browser?
Is like the one in virgin stores where you can ctrl+esc and get the
menu/desktop up
opensource, use it..
Pritpal Dhaliwal
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Monday, December 29, 2003 11:59 AM
To: Struts Users Mailing List
Subject: Re: Is there a way to prevent urls from being entered from the
browser?
So to prevent urls from being entered from
multibox, I need some coding for a dynamic array of
multiboxes with the same property value, how do I set the values in
the action class?
Thanks in advance
Regards
H.Rajesh
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Wednesday, December 24, 2003 5:00 PM
To: Struts Users
There are a number of options available here, i'd have a different def
that extends showList , I'd call this base.list and then have different
defs per list.
name=user.list extends=base.list
in fact i assumed you'd only have to over load body, you could even
have a def as the value of body.
Aren't tags usually in /WEB-INF?
On 27 Dec 2003, at 14:57, Michael Marrotte wrote:
%@ taglib uri=/tags/struts-bean prefix=bean %
is at the top of the JSP file and other bean:write tags are working
in the
same page...
-Original Message-
From: Sharad Acharya [mailto:[EMAIL PROTECTED]
taglib-uri/tags/struts-bean/taglib-uri
taglib-location/WEB-INF/struts-bean.tld/taglib-location
/taglib
All my tags are defined like this and all are working (even
bean:write) as
advertised, except in this one case.
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent
anything?
Do I need a taglib descriptor for c:out?
--Mike M.
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Saturday, December 27, 2003 10:08 AM
To: Struts Users Mailing List
Subject: Re: bean:write not writing?
Fair enough
The only other thing i can think of is to use jstl
You could try something like this.
public class Cart extends ActionForm {
private String subTotal;
private ArrayList items;
public BigDecimal getSubTotal() {
for(int i = 0;i items.size();i++) {
CartItem item = (CartItem)
You could over load on the insert
tiles:insert attribute=example.page
tiles:put name=body value=%= body % /
/titles:insert
or do it a specialized action. There are plenty of options although I
have trouble thinking of many scenarios where having 1000 different
definitions would be
If the forms are in different windows then instantiating new forms I
dont think will work. If you want a non javascript way of doing things
then you'll want to scope the master form to the session, and then keep
populating to from your subforms .
However you do this I imagine that scoping the
The checkboxes are selected depending on whether the value and the
property value match..
html:multibox property=myprop value=foo /
if myprop is set to foo it will be ticked..
On 24 Dec 2003, at 11:11, Rajesh, Harikrishnan (H.) wrote:
Hi,
I have a jsp input form with dynamically generated
html:text property=name value=%= user.getName() % /
or
html-el:text property=name value=${user.name} /
You can also populate in the refering action (assuming you've one), i
think this is better and keeps your form cleaner and thus perhaps more
reusable.
theForm.setName(Brian);
or
Just don't set the form value.
On 24 Dec 2003, at 15:15, AKostylev wrote:
I want to have select element without any selected values by default.
I can do this by setting selectedIndex=-1 or
value='not_existing_value' in JavaScript.
Can I do this with Struts functionality?
just need paramId to set the parameter name.
On 24 Dec 2003, at 15:59, Otávio Augusto wrote:
Hi all
I'm trying to add a parameter (yeah,i mean only one) to a link.
actually, it is an logic:iterator tag which generates a table, and one
of the columns is the link to an action which is going to
an option will only be selected by default if the form property has
been set to a value or there is a match in an available scope (like a
parameter with the same name as the form property). Otherwise it will
just do its thing.
I'd use a simple action without a formbean for something like a
//psuedo code.
List categoryList = Category.getList();
request.setAttribute(categories, categoryList.toArray());
logic:iterate id=category name=categories
/logic:iterate
I made the first bit up. But should give you the idea.
jsp:useBean id=categories
for this
collection
Will
- Original Message -
From: Mark Lowe [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Wednesday, December 24, 2003 12:31 PM
Subject: Re: Easy question: iterate
//psuedo code.
List categoryList = Category.getList();
request.setAttribute(categories
Hibernate throws that if it finds a null value on an indexed column.
Of example if you've a load of users and groups and say 3 users with
group_id of 999 and then someone removes group 999 you'd get this
exception.
On 24 Dec 2003, at 20:16, Otávio Augusto wrote:
hi all
Maybe this is an
Its actually expecting
theForm.get(aliasRef);
and
theForm.set(aliasRef,foo);
but this shouldn't make any difference in the jsp as
getAliasRef() and get(aliasRef).. are the same thing in the jsp (well
in terms of the jsp one uses to access the properties.)
Cheers Mark
On 23 Dec 2003, at
When are you getting this? Are you using dynaforms and/or validator
action forms?
On 20 Dec 2003, at 09:36, Raman wrote:
I am facing a error in Struts at BeanUtils.populate and not able to
trace the cause.
has anyone already face this problem? if yes what the cause. Pls help.
type Exception
, at 10:41, Raman wrote:
Hi I am using Validator form... is there something i am doing wrong in
that?
-- Raman
- Original Message -
From: Mark Lowe [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Saturday, December 20, 2003 4:11 PM
Subject: Re: BeanUtils.populate Error
]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Saturday, December 20, 2003 12:41 PM
Subject: Re: BeanUtils.populate Error
Hi I am using Validator form... is there something i am doing wrong
in
that?
-- Raman
- Original Message -
From: Mark Lowe [EMAIL PROTECTED]
To: Struts Users Mailing
Message -
From: Raman [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Saturday, December 20, 2003 12:41 PM
Subject: Re: BeanUtils.populate Error
Hi I am using Validator form... is there something i am doing wrong
in
that?
-- Raman
- Original Message -
From: Mark
We've only got the 1st phase done, and there's still much to be done but
http://www.murphyandnye.com
This is a B2C site, but just displays the products and allows simple
ordering at the moment. Next phase is the full ecommerce stuff. As it
happens its done with struts. We've carved this out
Same as nico really but you might like the el option
html-el:img page=${item} /
i'd have the image as a bean with a path, name and desc properties
html-el:img page=${item.path}
imageName=${item.name}
alt=${item.desc} /
Cheers Mark
On 19 Dec 2003, at 10:37, Nicolas De Loof
If you've an array of array list as your form property
form-property name=foo type=java.util.ArrayList /
or example
set(foo,int index,myvalue);
and/or
ArrayList list = new ArrayList();
theForm.set(foo,list);
IMO this is less hassle using action forms not dynaaction forms. If you
dont define
Nothing to add really just a few variations on a theme.
c:forEach var=num begin=0 end=999
html-el:option value=${num}
c:out value=${num} /
/html-el:option
/c:forEach
i think
c:forEach var=num begin=0 end=999
htmll:option value=%= num %%= num %
html:options name=numbers/
/html:select
Quoting Mark Lowe [EMAIL PROTECTED]:
Nothing to add really just a few variations on a theme.
c:forEach var=num begin=0 end=999
html-el:option value=${num}
c:out value=${num} /
/html-el:option
/c:forEach
i think
c:forEach var=num
just smile a little bit in a yeah right manner. he's just challenging
you or plain old bulshiting..
Sure struts isn't used in all b2c sites, but so what, is that a point ?
IMO If his team take to it then why not, its more a question of
java/jsp or not that struts.
On 18 Dec 2003, at 16:03, Max
DynaActionForms as cool as they are are more trouble than they're worth
unless its a small simple form. For one thing you don't find out what's
wrong until runtime.
I just use strings for dynaaction forms as it works, the problems our
in part caused (i think) by the conversions done by
No one's suggesting that anyone hangs them selves or that struts isn't
good. But the fact that this list sees a high influx of newbies,
getting battered with high-brow design concepts which while are very
interesting have a certain chocolate fire guard quality to them .
Easiest thing is to
reward. Thus the phrase was
born taking the piss its also where spending a penny came from
also.
Cheers Mark
Thank you,
Ed
- Original Message -
From: Mark Lowe [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Wednesday, December 17, 2003 10:33 AM
Subject: Re
be
exchanged by poorer folks for a financial reward. Thus the phrase was
born taking the piss its also where spending a penny came from.
Cheers Mark
Thank you,
Ed
- Original Message -
From: Mark Lowe [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Wednesday
Hi Marco
Perhaps try a none strust form element
input type=hidden name=methodToCall value=foo
rather than
html:hidden property=methodToCall value=foo /
also if possible in your situation
html:form action=/myaction.do?methodToCall=foo
Cheers Mark
On 17 Dec 2003, at 16:10, Marco Mistroni
Hi marco
well i think the problem your having is because you're using a dispatch
action
so the form is mapped to the action and its set to validate. You can
either separte yu dispatch actions into standard actions or hack it by
having a single action that calls your dispatch action much like
Dont know about using digester but html parser is a handy library.
http://htmlparser.sourceforge.net/
Might help you do what you want.
On 17 Dec 2003, at 22:45, Adam Hardy wrote:
Hi Christopher,
just a quick question about Digester, perhaps you can save me the
effort of reading up on it to
Mine's an opinion from someone who's pretty good on the presentation
and servlets stuff, and a lot greener in terms of model tier
development.
I've used torque and more recently hibernate on two separate projects..
Torque seems a bit dirtier, and a pain for deprecated dependencies, but
does
Sorry I forgot the reason for this cognitive preservation with
lazyList.. Arraylist works fine.. Even better if you ditch dyna forms
in favour of action forms..
On 15 Dec 2003, at 15:44, Andy Schmidgall wrote:
Robert,
I also could not get LazyList to work with our DynaForms.
-Andy
If you're determinted to do this in jsp rather than an action servlet
then
c:set var=creator value=${articleForm.creator} scope=session /
might do the job. I haven't tried it but I reckon it should work.
On 13 Dec 2003, at 06:44, Caroline Jen wrote:
The statement below in my JSP can write
Am I tree-barking or is there such a thing as tiles-el?
I seem to recall some mention of it on the dev list but I cant find any
reference to it on the struts site..
Anyone know anything?
Cheers Mark
-
To unsubscribe, e-mail:
Okay I've just had a sniff around the stuff in cvs, has any one used
tiles-el without any bleeding edge issues?
On 12 Dec 2003, at 10:33, Mark Lowe wrote:
Am I tree-barking or is there such a thing as tiles-el?
I seem to recall some mention of it on the dev list but I cant find
any
This is more out of curiosity than a need, but does anyone have a way
of drilling to ActionMessages previously ActionsErrors in jstl.
My understanding is that html:errors is deprecated but that silly
messagesPresent stuff does my suede in.
If been trying
c:out
Ted
Sorry I'm not really sure what you mean by chrome bean. Or how one
would go about scoping one to session while the action form (dyna or
otherwise) is scoped the request.
Do you mean you have a bean that persists beyond the form submission in
which you can store the user input until such a
I think you work with my brother.
Sorry thats OT , mail me off the list and I'll take a look..
Cheers Mark
On 11 Dec 2003, at 13:41, Rupinder Singh Mazara wrote:
Hi All ,
Can some help me in getting in setting up validation for data in the
following format
2, 4, 5-9, 18, 21-25, 50
or 2, 90,
If you mean how to you access get n set the indexed properties then
like this.
DynaActionForm theForm = (DynaActionForm) form;
ArrayList fooList = (ArrayList) theForm.get(myprop)
for(int i = 0;i fooList.size();i++) {
String foo = (String) fooList.get(i);
}
or to set..
ArrayList
What's the problem?
On 10 Dec 2003, at 21:20, Yee, Richard K,,DMDCWEST wrote:
I thought it worked, but it didn't.
-Richard
-Original Message-
From: Nifty Music [mailto:[EMAIL PROTECTED]
Sent: Wednesday, December 10, 2003 1:02 PM
To: [EMAIL PROTECTED]
Subject: RE: dynamically sized form
No the form (to the best of my knowledge) has to scoped to session, it
all looks like it works using request until you submit.
IMO you're best off using standard action forms for this kinda thing
dynaform get annoying for several reasons although they do work.
On 10 Dec 2003, at 22:01, Andy
Although its not a struts problem as such I do happen to be using
struts in my app..
Here some code as it will say more in less words that it will take to
explain
In my action servlet I have something like this..
code
response.setContentType(image/jpeg);
response.setHeader(Cache-Control,
The collection that you want to iterate through and the form property
aren't linked as such only when you nest the html:options tag in the
html:select tag
So your html:select form property is like any other form property, and
when submitted will only the form property will be set to only one
if you need futher help.
Regards,
David
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Monday, November 24, 2003 12:32 AM
To: Struts Users Mailing List
Subject: Hibernate plugin
After spending all night pissing around with various hibernate plugins
Opps!! an inconsistency.
SessionFactory sf = (SessionFactory)
ctx.lookup(foo:/hibernate/SessionFactory);
On 25 Nov 2003, at 16:07, Mark Lowe wrote:
Hi Gopal
David cleared this one up for me off the list (Big thanks), I assume
you've the same problem with folks trying to create publishing
Isn't handbags at 20 paces OT? ;o)
On 25 Nov 2003, at 16:12, [EMAIL PROTECTED] wrote:
Hi
I dont want to start a new thread, but the question has changed and if
u
cant help just stay away. You dont have right to ruin my day and
atleast i
am asking questions related to struts.You could have
After spending all night pissing around with various hibernate plugins
to provide a datasource to use with hibernate?
My JNDI datasource reports being okay in my container log,
Context path=/mn-test docBase=mn-test debug=5
reloadable=true crossContext=true
Logger
Sorry to post this group with an almost unrelated question, but I'm
sure someone on this list must be using xdoclet to generate hibernate
resources.
I wont take the piss and post the problem on this list but I would
appreciate it if anyone who's been using hibernatedoclet could drop me
a
I'm not sure how you've got things arranged but sounds like you could
do with having you team objects having a getMembers() method. If you
don't have this in you model then I guess its going to smart somewhat.
List teamList = someModelStuff.getTeams();
request.setAttribute(teams,
and CMP 2.0, Velocity, WebWork,
Sitemesh, POJO and Hibernate.
then check out http://xpetstore.sourceforge.net/
matt
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Saturday, November 22, 2003 7:23 AM
To: Struts Users Mailing List
Subject: [OT] xdoclet + hibernate
Sorry
forum:
http://forum.hibernate.org
Regards,
David
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Saturday, November 22, 2003 9:32 AM
To: Struts Users Mailing List
Subject: Re: [OT] xdoclet + hibernate
Thanks Matt
I found the xdoclet list just after I posted this question
You'll hear a lot of shit talked about tiles.
This article explains the lot
http://www.javaworld.com/javaworld/jw-01-2002/jw-0104-tilestrut.html
I use the Tiles inheritance solution. Saves all those jsp's with
forwards and redirects. The secret is that you always need to us an
action
business solutions
Specialiste en solutions d'affaires interactives
14 Commerce Place, 5th floor
Nun's Island, QC H4E 1T5
t: 514 768-1000
f: 514 768-7680
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: November 21, 2003 12:25
To: Struts Users Mailing List
Subject: Re
I tend to use arraylist rather than an array, works a treat the only
work around is having to put the list in the request or session as well
as the form.
ArrayList rateList = new ArrayList();
bla , bla..
theForm.set(rate,rateList);
request.setAttribute(rate,rateList);
..
logic:iterate id=r
If you've been looking through the archives you'll know that datasource
in struts config is considered the devil's spawn and its use isn't
recommended.
Have a look at you TC docs as configuring a JNDI datasource is web xml.
You could botch a try catch statement that forwards to your error
On 21 Nov 2003, at 17:18, Yee, Richard K,,DMDCWEST wrote:
Matt,
The answer to your main question is, No. You don't have to specify
the
form as the input of the preloader. You don't even really have to have
a
separate 'pre-loader' action for this form. In any action that will
forward
to your
On 21 Nov 2003, at 18:29, Matt Bathje wrote:
DynaActionForm taxRatesForm = new DynaActionForm();
and
taxRatesForm.set(taxRates, allTaxRates);
request.setAttribute(taxRates,
allTaxRates);
Creating a form in the action servlet is one sure way to piss the
folks
off who have to maintain the app. You
Dick
Oh well... There's just no telling some folks..
[OT] But then I've just seen who you're working for.. Sleep well..
On 21 Nov 2003, at 21:04, Yee, Richard K,,DMDCWEST wrote:
Matt,
I found out that using new DynaActionForm()inside of the
PreLoaderAction.execute() doesn't work. It gives a
? Or
is it something else that you find objectionable?
-Richard
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Friday, November 21, 2003 3:38 PM
To: Struts Users Mailing List
Subject: Re: dynamically sized form (mostly solved)
Dick
Oh well... There's just no telling some folks
No its not your imagination.. Some of the questions are just about
basic tag which is well documented with examples (for those who first
language isn't english).
I usually don't believe in stupid questions, as all questions are good,
but alas i've been proved wrong.
On 20 Nov 2003, at
So your end user has to select 1 of 1800 options 8 times on one page?
I've never had trouble with options but then again i've never smoked
enough crack to think select menus with 1800 options would be a good
thing.
As a test you could use model 1 jsp or/and jstl to compare.,
c:forEach
I had to use the destdir attribute
strutsconfigxml version=1.1 destdir=${build.dir}/WEB-INF /
On 12 Nov 2003, at 12:23, [EMAIL PROTECTED] wrote:
Yes it is quitte easy:
In build.xml
target name=xdoclet.web
taskdef
name=webdoclet
Nottingham Forest beat Luton 2 -1
I assume the rest of your question was an attempt at humor.
Cheers Mark
On Thursday, November 6, 2003, at 05:03 AM, [EMAIL PROTECTED] wrote:
This is off topic but I couldn't wait til casual friday...
I have the following problem in my web-app.
When I try and
what do you mean by execute my (your) submit.jsp ?
I could be wrong, but looks like you're trying to be a bit of a picasso
with your property names.
On Tuesday, November 4, 2003, at 10:50 AM, sairam manda wrote:
Hello Sir,
I get blank page when I execute my submit.jsp . I have a simple
while(rs.next()) {
Map teacher = new HashMap();
teacher.put(firstName,rs.getString(firstName));
teacherList.add(teacher);
}
teacherForm.set(teachers, teacherList);
request.setAttribute (teachers, teacherList.toArray());
Cheers Mark
On Monday, November 3, 2003, at 07:35
It works alright but last time i played with these beanutil's toys it
was understandably slow. A little less slower is getting the
resultsetmetadata and using them as your property names.
IMO its better to make some beans and populate them with the result set
values, until you've time to put a
Just define the form property as a string
form-property name=date type=java.lang.String /
when you get the date from you model either format it in your referring
class, using DateFormat.
java.util.Date date = new java.util.Date( dateString );
now you can format and then feed it back to the
Its not the best way, but a reasonable and simple way of dealing with
this stuff is to use a try/catch statement in you action servlet.
try {
//your code that does the search stuff
bla bla
return (mapping.findForward(success));
} catch (WhatEverExceptionYouWantToThrow e) {
//print
Perhaps you don't need to pass the id in as an argument. I'd just wrap
the action in a js function
function setupUserForm() {
alert( 'setUpUsersForm.do?action=retrieveuserId=c:out
value=${param.userId} / ' );
}
onchange=setupUserForm() ..
On Wednesday, October 29, 2003, at 11:12 AM,
In fact ignore my suggestion, I was silly and assumed the userId was
taken somewhere else but the form.
On Wednesday, October 29, 2003, at 11:33 AM, Mark Lowe wrote:
Perhaps you don't need to pass the id in as an argument. I'd just wrap
the action in a js function
function setupUserForm
If the variable users.userAccount is in an available scope it will be
there anyway, without all the messing around.
..
session.setAttribute(users,...);
..
html:hidden property=users.userAccount /
if you've a getUserAccount() method as a property of user it will work
like this.
On Wednesday,
I didn't know the postgres was faster than oracle.. I agree that its
the canine's genitalia .. But I still thought oracle was the daddy when
it came to speed. Is that just read access or everything?
On Wednesday, October 29, 2003, at 02:52 PM, Vic Cekvenich wrote:
This might confuse you more
/
db_compare.h
tml
Mark Lowe wrote:
I didn't know the postgres was faster than oracle.. I agree that its
the
canine's genitalia .. But I still thought oracle was the daddy when
it
came to speed. Is that just read access or everything?
On Wednesday, October 29, 2003, at 02:52 PM, Vic Cekvenich wrote
html parser is what you want..
http://htmlparser.sourceforge.net/
On Wednesday, October 29, 2003, at 10:09 PM, Greg Dunn wrote:
Does anyone know of any free Java I can incorporate in my app that
will take
a String of HTML and strip the tags out?
Greg
That's okay Rajat as I said I know what its like to up against the
wire..
I've found ArrayList works better in dynaActionForms especially if
you're dynamically generating forms. I think this because its a big fat
pain in the arse to create new dynabeans (have a play with bean utils
for a day
Try this like George said
head
html:base /
/head
Cheers Mark
On Tuesday, October 28, 2003, at 03:55 PM, javen fang wrote:
but if in left.jsp include struts tags, or it mapping
from struts action, then relative uri will fail, and
absolute uri is required:
img
Forget indexed properties, all that stuff..
Does each state have many bids, modes and/or calls?
If you're not clear about this in the first place then you'll be in
trouble. Until you stop spamming the list and think about what you're
doing then you wont get anywhere.
On Monday, October 27,
You can use the jndi datasource that you define in web.xml rather than
struts.
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-
examples-howto.html
The struts datasource is deprecated generally. Ideally you have your db
connection stuff in your model layer. If this means
As a web user I tend to have problems with these sorts of pages as I
don't use IE.
A lot of downloads where this sort of thing goes on often i end up with
the file name of a php page rather than zip and stuff like that. My
guess is is that IE is doing some of the work somewhere along the line,
Need to know what your validator.xml looks like and form-bean stuff in
your struts-config.
Just sticking html:radio indexed=true .. doesn't say very much.. and
just because its displayed doesn't mean its working..
So give more detail have read the documents. Forget about databases for
now and
I need to know how to iterate the data and also in case
of an error, it should re populate the html:text with the data from
the array.
Somebody help!! :(((99
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Sunday, October 26, 2003 4:47 AM
To: Struts Users Mailing
. Hope you will forgive me, I didn't mean to
hurt or upset anyone.
-Original Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED]
Sent: Sunday, October 26, 2003 8:19 AM
To: Struts Users Mailing List
Subject: Re: Multiple parameters
Look man I know what its like being up against the wire
Message-
From: Mark Lowe [mailto:[EMAIL PROTECTED] Sent: Sunday, October
26, 2003 4:47 AM
To: Struts Users Mailing List
Subject: Re: Multiple parameters
Need to know what your validator.xml looks like and form-bean stuff
in your struts-config.
Just sticking html:radio indexed=true .. doesn't say
The performance costs are low, but using an action just to forward to
different views does have a very small performance cost. Run a stress
test and you'll see.
The benefits however of doing everything via actions, far outweigh the
slight performance hit. You can start to think about your app
I'd run an action when you click the radio button and regenerate the
form, you'll have to manage this when setting the values that you know
longer need.
The following with serve as some psuedo code to express what I mean.
script langage=javascript type=text/javascript
function toggle()
If you're using struts 1.1 you can define a form property as an
arrayList to do the same thing..
form-property name=myproperty type=java.util.ArrayList /
...
action name=myForm scope=session ..
..
ArrayList myList = new ArrayList()
theForm.set(myproperty,myList);
..
logic:iterate id=foo
I'm not sure if the forEach way works with indexed form properties. I
tried and the html:text tags seems to be a tad oblivious to the fact
they were nested in a loop.
form-property name=cities type=java.util.ArrayList /
..
//also you need to scope to session
action path=/process-form
Those variable don't really need to be global.
function getValue(form, optionName,hiddenValue) {
s = form.elements[optionName];
for(i = 0;i s.options.length;i++) {
if(s.options[i].value == hiddenValue) {
s.options[i].selected = true;
I don't know how to tolerate that eclipse nonsense.
Jar bundler that comes with apple dev tools lets you make double
clickable mac style (apple menu bar as well) apps out of java utils
like antidote, jcvs and struts console. With a copy of bbedit or even
project builder as a text editor.
I
, at 02:55 PM, Jacob Wilson wrote:
Thanks for the help Mark... when I do this, it says
elements.optionName is not null or an object... Any clue??? Thanks!
Mark Lowe [EMAIL PROTECTED] wrote:Those variable don't really
need to be global.
function getValue(form, optionName,hiddenValue) {
s
:
Thanks for the help Mark... when I do this, it says
elements.optionName is not null or an object... Any clue??? Thanks!
Mark Lowe [EMAIL PROTECTED] wrote:Those variable don't really
need to be global.
function getValue(form, optionName,hiddenValue) {
s = form.elements[optionName];
for(i = 0;i
s.options.length;i++) {
if(s.options[i].value == hiddenValue) {
s.options[i].selected = true;
break;
}
}
}
optionName is the element name and the error elements.optionName is
not null or an object when I try to use s.options.length...
Mark Lowe [EMAIL PROTECTED] wrote:
You can specify an index
You may have taken the trouble to reflect on why there were no
responses to your original post..
DynaActionForm theForm = (DynaActionForm) form;
Map formMap = theForm.getMap();
..or using beanutils...
Map formMap = BeanUtils.describe( theForm );
session.setAttribute(details,formMap);
...
//in
The id is the name of whatever you want to call each object thats being
spat out during the iteration.
Have a play with this in a jsp page to get used to the tags. And then
you can move the scriptlet out when your a bit more familiar with stuff.
%
java.util.Map mapOne = new
301 - 400 of 636 matches
Mail list logo