HI
In struts if we use ( in web.xml) url-pattern/*.dourl-pattern we will never
get the full path or file name of the JSP's or Action's
Check it Once
Regards
Kumar
Kam Lung Leung [EMAIL PROTECTED] wrote:
Hi,
I am working on a project that uses Tiles and Structs.
I have the following
If you want to just forward the request along, just add any parameters
to the request object via the setAttribute method.
-Original Message-
From: Frank W. Zammetti [mailto:[EMAIL PROTECTED]
Sent: 14 September 2005 08:46
To: Struts Users Mailing List
Subject: Re: Adding parameters to
hi
i have the solution
DataSource aDataSource = (DataSource)
actionServlet.getServletContext().getAttribute(dataBase1);
i found the solution here
http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topicf=58t=001155
Thank you,
Thibaut Lassalle
Martin Gainty a écrit :
Hello
Hi!
What is the corresponding code in Struts for the given html
select
option value=2Two/option
option value=1 selected=selectedone/option
/select
-Thanks in Advance
Jeevan
-
Yahoo! for Good
Click here to donate to the Hurricane Katrina
Frank W. Zammetti wrote:
Xavier Vanderstukken wrote:
IS that class really performs a redirect request?
Can I use the setForward method to false to performs a forward with
parameters?
Interesting question... someone can correct me if I'm wrong, but I
believe the answer is no. Well, to be
Frank W. Zammetti wrote:
Laurie Harper wrote:
Why do you say that's a bad practice? It's actually both supported and
recommended; in fact, the 'name' attribute is deprecated in favour of
the 'id' attribute so 'id' is the only way to target CSS to a
particular page element rather than an
Hi There,
I am stuck at one place while working with tiles, please help.
I have my tiles-defs.xml as this:
tiles-definitions
definition name=.mainLayout path=/WEB-INF/tiles/layout.jsp
put name=title value=Welcome to Net Model/
put name=pageheading value=/
put name=header
Cross-posting to the dev list for committer approval of the proposed
changes:
Niall Pemberton wrote:
I agree, not trimming!
Personally I don't have a problem with making the change (i.e. checking for
zero length strings) in the html taglib, since an easy one line change will
catch alot of
Hi All,
The following code doesnt work :
tiles:insert definition=header.page
tiles:put name=page-heading value=tiles:getAsString name=heading/ /
/tiles:insert
because the 'value' attribute contains an tiles tag instead of a static value,
Please suggest a solution for this
Thanks,
Deepesh.
Hi,
We want to deploy an struts application to live server (oracle 10g IAS). This
application is working properly on our local server. But when we want to deploy
and start this app. it gives an error like this.
500 Internal Server Error
java.lang.NullPointerException
at
Hi Deepesh,
Try this, it worked for me:
tiles:insert definition=header.page
tiles:put name=page-headingtiles:getAsString
name=heading//tiles:put
/tiles:insert
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: 14 September 2005 14:15
To: Struts Users
Thanks Ron, that worked perfect :)
- Original Message -
From: Holshausen, Ron [EMAIL PROTECTED]
To: Struts Users Mailing List user@struts.apache.org
Sent: Wednesday, September 14, 2005 5:30 PM
Subject: RE: Using Tiles tag inside a tile tag
Hi Deepesh,
Try this, it worked for me:
actually if we are adhering to 'Struts' way of acquiring the DataSource
Action class has a getDataSource which takes a request parameter (and
optional 2nd param of key for multiple data-sources)
Hi Guys,
http://struts.apache.org/faqs/indexedprops.html
Subsection List-Backed Indexed Properties contains this code:
package org.apache.struts.webapp.exercise;
import org.apache.struts.action.ActionForm;
public class StringBean2 extends ActionForm {
private String strAry[] = { String 0,
Hello,
I want to write something like this in a jsp file
script language=javascript
function f() {
return bean:write name=some_bean property=a_property/;
}
/script
but the bean:write tag isn't processed. So how can I make it processed?
Thank you.
I would make it part of a custom tag. This will also avoid the
copy/paste of javascript in all the jsps.
Bala
http://groups.yahoo.com/group/OOAD_UML/
-Original Message-
From: Thai Dang Vu [mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 14, 2005 8:59 AM
To: user@struts.apache.org
Hi,
I have used the JSTL c:out tag to do this, e.g., c:out
value=${some_bean.a_property}/;
-Original Message-
From: Thai Dang Vu [mailto:[EMAIL PROTECTED]
Sent: 14 September 2005 15:59
To: user@struts.apache.org
Subject: How to create on-the-fly javascript code?
Hello,
I want to write
Hi Ron,
We're actually talking about two different things... there are request
PARAMETERS and request ATTRIBUTES. What you say is of course accurate,
you can call setAttribute() on a request and forward it along and you'll
have access to those attributes. But that is different from parameters.
Indeed...This is a good solution for creating html javascript
If you are using javascript for validation
(based on the validation rules loaded by the ValidatorPlugIn)
you can use the html:javascript Tag
documentation available here at
On Wed, September 14, 2005 6:35 am, Laurie Harper said:
I never said you *shouldn't* use 'class' to style elements :-)
True enough :)
That's the right answer when you want to apply the same set of styles to
multiple elements (although even without the 'class' attribute here,
you'd still only
You've got a lot of experiences Joe. I forgot to put the taglib declaration at
the beginning of the jsp file. Sorry for my stupid question.
[EMAIL PROTECTED] 9/14/2005 9:15:07 AM
At 8:59 AM -0400 9/14/05, Thai Dang Vu wrote:
Hello,
I want to write something like this in a jsp file
script
On Wed, September 14, 2005 6:35 am, Laurie Harper said:
I never said you *shouldn't* use 'class' to style elements :-)
True enough :)
That's the right answer when you want to apply the same set of styles to
multiple elements (although even without the 'class' attribute here,
you'd still
Hi,
I'm new to this group so first of all I'm pleased to have the opportunity to
ask questions here.
My question(s):
1) I'm trying to write an application that supports i18n with Struts. I use
DynaActionForm for my forms, so I defined them with initial values, e.g.:
form-bean name=productForm
I would say that the code that is yielded when you reference the form by
name is clearer and thus better regardless and I would throw away the
possibility of someone changing the name in the config file. It's more
important that the code be as explicit IMO.
I definitely like clean code
On Wed, September 14, 2005 10:15 am, Tamas Szabo said:
I definitely like clean code and if I'm looking at the generated HTML
I agree that it is cleaner if you reference the form by name.
But in the JSP it's just doesn't seem right to reference a form
name that will appear only in the generated
You have to use an initial value of 1000.
form-bean name=productForm
type=org.apache.struts.validator.DynaValidatorForm
form-property name=listprice type=java.lang.String initial=1000
/
/form-bean
Then where you print this initial value, at your jsp, use formatting
options:
Frank W. Zammetti wrote:
If I don't want to use scripting I guess I could use something like
${requestScope['org.apache.struts.action.mapping.instance'].name}
But what if the Globals.MAPPING_KEY will change ... :-)
That's why you want to use the field in Globals... if the key under which
the
I think your 'semantics' arugment may be confusing two orthogonal sets
of semantics, but I do see where you're coming from.
We're well off-topic so I'm keeping this brief, but feel free to follow
up off-list if you want to discuss further.
L.
Frank W. Zammetti wrote:
On Wed, September 14,
I don't have the 1.1 source code checked out so I don't know exactly
what it's failing on but I would suggest checking two things:
1) make sure all the attribute values you're passing into the tag are
valid, and
2) make sure the form bean for the enclosing form tag is being found
(i.e. that
And for the validator issue, you can localize your validation rules by
defining a seperate set for each locale. I don't know if there's a way
to make the standard, included validations locale-aware but you can
define alternates where necessary if not. Also, Struts 1.3 will
introduce an
http://svn.apache.org/builds/struts/maven/trunk/site-test/struts-taglib/tlddoc/html/tld-summary.html
See, in particular, the select, option, options, and optionsCollection tags.
L.
Kade Jeevan Kumar wrote:
Hi!
What is the corresponding code in Struts for the given html
select
option
On 9/13/05, Laurie Harper [EMAIL PROTECTED] wrote:
Jeff Deskins wrote:
Is there a way to display all inputs/textareas of a struts form as plain
text for a printer-friendly version of a page?
This would be similar to how the readonly attribute of a form currently
works in struts, by
Be mindful that Oracle ADF Runtime needs to be installed on the target
webapp server check out
http://www.oracle.com/technology/products/jdev/howtos/10g/adf_runtime_update_howto.html
HTH,
Martin-
- Original Message -
From: Laurie Harper [EMAIL PROTECTED]
To: user@struts.apache.org
Martin, Oracle ADF Runtime needs to be installed...but if it is used ;)
I think Erol is not using ADF.
Erol, keep in mind that tomcat and IAS are *different*. I saw a similar
error with tomcat doing automatic string-number cast, and IAS not.
Martin Gainty escribió:
Be mindful that Oracle
At 09:03 PM 9/13/2005, you wrote:
I'm not sure about this; at worst, wouldn't it be sufficient to recompile
just the Struts taglibs against the Servlet 2.4 / JSP 2.0 APIs? There
should be no need to upgrade to J2SE 5 or to recompile any other part of
Struts as far as I can see.
That being
Test please ignore, switched account to gmail and somehow my mails
seems to be ignored...
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
On Wed, September 14, 2005 11:15 am, Laurie Harper said:
I think your 'semantics' arugment may be confusing two orthogonal sets
of semantics, but I do see where you're coming from.
Could be. Wouldn't be the first time :)
We're well off-topic so I'm keeping this brief, but feel free to follow
Laurie had the right idea... you can disable the border for form fields,
and that's what you would want your stylesheet to do. You may run into
some fields that can't be controlled like that, I've never tried to do
them all (specifically I'm thinking of selects, which seem to be a world
unto
The problem is that the html:text tag doesn't have a formatKey-attribute
and I want the initial value to be displayed in a text-field, not as a pure
html-output.
In other words: I need struts to make a input type=text
name=propertyName value=1000,00 out of a ...initial=1000 with
German locale set
Hallo
I just tried Exadel. I don't like because I don't see what I am doing. I
tried the tutorial. It has a graphic display to configure the
struts-config.xml. Editing the struts-config.xml is only a minimum effort in
a web application. The main part is creating and developing the JSP File and
input type=text name=productForm.listprice value=bean:write
name=productForm property=listprice formatKey=format.number /
Michael Ewers escribió:
The problem is that the html:text tag doesn't have a formatKey-attribute
and I want the initial value to be displayed in a text-field, not as a
Rich,
That is the main reason I ZIP down my complete eclipse Directory just prior
to Installing anything
NEW into my eclipse enviroment. Just in case I don't like the plug-in or
the plug-in has UPDATE
problems..
Steve
-Original Message-
From: R. Markham [mailto:[EMAIL PROTECTED]
Sent:
Yeah, no good... Below is a quick test you can play with. I couldn't
figure out how to get the selects to work like the rest. Checkboxes and
radios too it doesn't like you can do much with, but they may be OK. Here
you go though, pretty simple stuff...
html
head
titleTest/title
style
Even better, use display:none; on the checkboxes and radios so everything
lines up right. Updated:
html
head
titleTest/title
style
.cssNoBorder {
border : 0 solid #ff;
overflow : hidden;
background-color : #ff;
}
/style
/head
body style=background-color;#ff;
table
I have seen code in open source projects like Commons Chain which does
not use some of the good design principles like command-query
separation. Are decisions like these made without any justifications? If
yes, then it needs to be documented. It is overwhelming to someone who
is new to open source
That doesn't allow the use of the Struts HTML tags though, since you
can't use a tag in a tag attribute... This will work, though:
html:text name=...
jsp:attribute name=value
bean:write name=productForm property=listprice
formatKey=format.number/
/jsp:attribute
Two notes:
1. Be careful when modifying ActionForwards to make sure that you aren't
modifying the shared, system-wide instance. That can be a nasty side
effect. You can make a copy of the ActionForward object, change it, and
return the copy from your Action.execute() method to get around this
On Wed, September 14, 2005 2:37 pm, Max Cooper said:
Two notes:
1. Be careful when modifying ActionForwards to make sure that you aren't
modifying the shared, system-wide instance. That can be a nasty side
effect. You can make a copy of the ActionForward object, change it, and
return the
Can anyone see a reason why the html:text implementation in struts-html.tld
doesn't support a formatKey attribute?
To whom can I send patches that I write?
Thanks,
Michael.
That doesn't allow the use of the Struts HTML tags though, since you
can't use a tag in a tag attribute... This will
Michael Ewers wrote:
Can anyone see a reason why the html:text implementation in struts-html.tld
doesn't support a formatKey attribute?
I guess because there are already ways to format values which can be
composed with html:text/ so it doesn't *need* to support it. If
there's some reason
From: Laurie Harper [EMAIL PROTECTED]
Michael Ewers wrote:
Can anyone see a reason why the html:text implementation in
struts-html.tld
doesn't support a formatKey attribute?
I guess because there are already ways to format values which can be
composed with html:text/ so it doesn't *need*
I was thinking about this some more. Both you and the bugzilla ticket had
this issue
where theres an either/or situation with attributes - (e.g. either alt or
altKey) - maybe
we should stick focused on that. Attributes that are just passed through
your tag
files shouldn't be an issue? That way, I
I have an Action which sets a populated List in a DynaValidatorForm Bean.
The input of the ActionMapping in the struts-config simply points back to
the .jsp page (actually a tile def) and uses html:errors/ to print out the
error messages.
If no validation problems occur, there aren't any
/--\
| Action | populates list
\--/
|
V
/--\
| JSP/Tiles|
\--/
The list is not being populated when validation fails as framework is
throwing back request to JSP/Tiles without running the population
code. This is very well expected
What about keeping the list in form-bean? It is DynaForm, so you can
populate using form.set(mylist, mylisy); and retrieve back using
${form.map.mylist} (or RT equivalent of it).
If you put in session, you have to take care of removal. In this case
Struts will take care of it and recycle it.
On
Thanks for the info on this subject. They have been a big help.
One of the problems with textareas is in printing the rest of the text
beyond the scrolled view (when you have more text than is visible in the
textarea). However, it will work in IE with a print style of
{overflow:visible} - but
The idea of updating the tags was proposed by someone else in the past
two weeks ironically. I think there was some interest in it (I seem to
remember it being part of a larger proposal, but that particular part
seemed to elicit some support).
Frank
Jeff Deskins wrote:
Thanks for the info
Hi Laurie,
Thank you for helping the question. It seem to be alot of works to prevent the
path shows up at the address bar. I though by seting up the Tile definition
like below should be good. When a user press the Administration link, Tile
forward the reference to the Global forward named
Hi Praveen,
Thank you for helping. Can you explain what must I do in the web.xml file.
I do have the url-pattern/*.dourl-pattern in the web.xml and I saw the full
path shows up at the address bar.
Regards,
Kam Lung Leung
Struts Users Mailing List user@struts.apache.org wrote:
HI
In
Control Panel | Add or remove programs
Alternatively, C:\ExadelStudio\UninstallerData\Uninstall.exe
Kind regards
mc
On 14 Sep 2005 at 18:58, R. Markham wrote:
Hallo
I just tried Exadel. I don't like because I don't see what I am doing. I
tried the tutorial. It has a graphic display to
The decisions are made by the volunteers who write the code. As the
code is submitted to the repository, the changes are submitted to the
development list for peer review. If someone sees a better way to
write the code, the best thing is to submit a patch demonstrating the
change. In an Apache
Here's a solution for you, but I don't know its applicability to Firefox,
and won't work for inline styling.
1. Start by outputting the information in a text area and in a div/span.
2. Give each different class names/ids, say foo and bar respectivly.
3. Link to your stylesheet or declare your
I'm using a LabelValueBean, as I need to have a name be diplayed, and a
value be reported back to the form.
I have no problems creating a List of LabelValueBean's, setting them into
the request like so:
request.setAttribute(myLVBList, myLVBList);
... and outputting them on the .jsp like so:
Woops, should have read the rest of the thread as Jeff Deskins had already
brought up the media attribute.
Niall Pemberton wrote:
I was thinking about this some more. Both you and the bugzilla ticket had
this issue
where theres an either/or situation with attributes - (e.g. either alt or
altKey) - maybe
we should stick focused on that. Attributes that are just passed through
your tag
files shouldn't
Hi there,
I am quite new to JSP and struts. So - as I suppose - quite lame question
;-)
In order to implement bread crumbs feature I have a collection bean,
containing simple PathElement objects in request scope. Each PathElement
contains two attributes:
- titleKey (for resource key
From: Wojciech Ciesielski [EMAIL PROTECTED]
In order to implement bread crumbs feature I have a collection bean,
You might want to take a look at Struts Layout, it already has support for
breadcrumbs:
http://struts.application-servers.com/doc/tags/crumbs.html
--
Wendy Smoak
Define a scripting variable with the actionUrl and use that in your
html:link/ like so
logic:iterate id=element name=PATH_ELEMENTS
bean:define id=actionbean:write name=element
property=actionUri//bean:define
html:link action=%=action%bean:message name=element
property=titleKey//html:link
It is possible. Have a method on your ActionForm which returns a
java.util.Collection of org.apache.struts.util.LabelValueBean's and use it
using html:optionsCollection/ in the jsp
For eg:
public Collection getMyLVBList() {
Collection options = new ArrayList();
options.add(new
I'm hoping someone here can help me with this.
I'm getting inconsistency on this issue and googling hasn't helped.
I'm running a struts app on OS X with Jrun 4 and Apache 2. When I use
c:redirect url=/general/getInfo.do / in the index.jsp file it appends
the jsessionid to it and apache doesn't
Define action aliases to your jsps and use those actions for eg:
action path=index forward=/WebComponemt/Presentation/index.jsp/
and use that in your tiles menu
putList name=items
item value=Home link=/index.do /
/putList
You can do some processing on the list of items that are read by the
If I am rewriting existing code, copyrighted by Apache, should I
change the copyright? ;) Some code is heavily modified, some is just
barely.
Michael.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail:
A tag would be handy for this ...
Indeed there is one, please take a look at bean:struts/
Thank you
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Hi Michael,
I think section 4 of the Apache License 2.0 answers this pretty well,
but it doesn't seem to differentiate between large-scale changes and
trivial little ones, so I would think this applies regardless...
4. Redistribution. You may reproduce and distribute copies of the Work
or
75 matches
Mail list logo