Re: box with lot of . Need help.

2005-06-05 Thread Nitesh

Looks like a Javascript problem...
try this script... hope it helps.

 function addMapping(objSourceElement, objTargetElement)
 {

   if (objSourceElement.selectedIndex == -1)
   {
alert("Please select the tasks from the Available Tasks");
return;
   }

var objectsToRemove = new Array();
for(i=0;i  objTargetElement.options[objTargetElement.options.length-1].text = 
objSourceElement.options[i].text;
  objTargetElement.options[objTargetElement.options.length-1].value = 
objSourceElement.options[i].value;

  objectsToRemove[objectsToRemove.length] = objSourceElement.options[i];
 }
}
for(k=0;k- Original Message - 
From: "senthil Kumar" <[EMAIL PROTECTED]>

To: 
Sent: Monday, June 06, 2005 11:06 AM
Subject:  box with lot of . Need help.



Hi all.,


I have a  box with lot of . I want to add a selected 
 with another  box once click a add button.


Now i can add one by one.But  once i selected more than one options, still 
it is adding one, remaining all are deleted.



I want add to another select box once selected more than one options also.

Any can help me.

Here i am putting my JavaScript code.

Thanks in advance.
Regs.
senthil

onclick="addMapping(this.form.taskList, this.form.mappingTask);" 
tabindex="12"/>






// This function gets called when ADD button clicked
 function addMapping(objSourceElement, objTargetElement)
 {

   if (objSourceElement.selectedIndex == -1)
   {
alert("Please select the tasks from the Available Tasks");
return;
   }

   var aryTempSourceOptions = new Array();
   var x = 0;
   var intTargetLen = objTargetElement.length++;

   //populate the mapping name list box with CSV file column and the 
sample field column
   objTargetElement.options[intTargetLen].text = 
objSourceElement.options[objSourceElement.selectedIndex].text;
   objTargetElement.options[intTargetLen].value = 
objSourceElement.options[objSourceElement.selectedIndex].value;



   //This is to recreate the fileheaders list box
   for (var i = 0; i < objSourceElement.length; i++) {
if (!objSourceElement.options[i].selected) {
 var objTempValues = new Object();
 objTempValues.text = objSourceElement.options[i].text;
 objTempValues.value = objSourceElement.options[i].value; 
aryTempSourceOptions[x] = objTempValues;

 x++;
}
   }
   objSourceElement.length = aryTempSourceOptions.length;
   for (var i = 0; i < aryTempSourceOptions.length; i++) {
 objSourceElement.options[i].text = aryTempSourceOptions[i].text; 
objSourceElement.options[i].value = aryTempSourceOptions[i].value;

   }
   x = 0;
   aryTempSourceOptions = new Array();
   objSourceElement.selectedIndex = -1;
 }

This e-mail and any files transmitted with it are for the sole use of the 
intended recipient(s) and may contain confidential and privileged 
information. If you are not the intended recipient or received it in 
error, please contact the sender by reply e-mail and destroy all copies of 
the original message. Please do not copy it for any purpose or disclose 
its contents.


Copyright Tarang Software Technologies Pvt. Ltd. 2004. All rights Reserved 



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



box with lot of . Need help.

2005-06-05 Thread senthil Kumar
Hi all.,


 I have a  box with lot of . I want to add a selected 
 with another  box once click a add button.

Now i can add one by one.But  once i selected more than one options, still it 
is adding one, remaining all are deleted.


I want add to another select box once selected more than one options also.

Any can help me.

Here i am putting my JavaScript code.

Thanks in advance.
Regs.
senthil







// This function gets called when ADD button clicked
  function addMapping(objSourceElement, objTargetElement)
  {
   
if (objSourceElement.selectedIndex == -1)
{
 alert("Please select the tasks from the Available Tasks");
 return;
}   
  
var aryTempSourceOptions = new Array();
var x = 0;
var intTargetLen = objTargetElement.length++;
   
//populate the mapping name list box with CSV file column and the sample 
field column
objTargetElement.options[intTargetLen].text = 
objSourceElement.options[objSourceElement.selectedIndex].text;
objTargetElement.options[intTargetLen].value = 
objSourceElement.options[objSourceElement.selectedIndex].value;

 
//This is to recreate the fileheaders list box
for (var i = 0; i < objSourceElement.length; i++) {
 if (!objSourceElement.options[i].selected) {
  var objTempValues = new Object();
  objTempValues.text = objSourceElement.options[i].text;
  objTempValues.value = objSourceElement.options[i].value;
aryTempSourceOptions[x] = objTempValues;
  x++;
 }
}
objSourceElement.length = aryTempSourceOptions.length;
for (var i = 0; i < aryTempSourceOptions.length; i++) {
  objSourceElement.options[i].text = aryTempSourceOptions[i].text;  
  objSourceElement.options[i].value = aryTempSourceOptions[i].value;
} 
x = 0;
aryTempSourceOptions = new Array();
objSourceElement.selectedIndex = -1; 
  }

This e-mail and any files transmitted with it are for the sole use of the 
intended recipient(s) and may contain confidential and privileged information. 
If you are not the intended recipient or received it in error, please contact 
the sender by reply e-mail and destroy all copies of the original message. 
Please do not copy it for any purpose or disclose its contents.

Copyright Tarang Software Technologies Pvt. Ltd. 2004. All rights Reserved

Re: Problem using indexed properties and validator framework (fixed)

2005-06-05 Thread Nitesh

Thanks for all the help John.
I could work it out tweaking on your solution.

Regards,
Nitesh

- Original Message - 
From: "John Fitzpatrick" <[EMAIL PROTECTED]>

To: "Struts Users Mailing List" 
Sent: Friday, June 03, 2005 6:06 PM
Subject: Re: Problem using indexed properties and validator framework



In the struts-config.xml:

   
   
   


   
   
 
   


In EditUsersAction.java execute method

   // get collection of users from the database
   Collection users = getUserBeans ();

   // put collection into form as an array for editing
   form.set ( "users", users.toArray ( new UserBean[0] ) );

In editUsers.jsp

   
   
   

In the produced HTML:

   

If you need to client side validation, you'll probably need to write your
own JSP to deal with the element above.

As for using validate.xml to validate on the server side. I've never tried
it with arrays, I just iterate over them in the validate (...) method of 
the

form, like so:

   UserBean users[] = (UserBean[]) form.get ( "users" );
   for ( int i = 0; i < users.length; i++ ) {
   // check on the attributes of UserBean users[i]
   }

Hope that example clears it up for you.

John



On 20050603 5:05 AM, "Nitesh" <[EMAIL PROTECTED]> wrote:


Thanks for the answer John...

Could you give me an example as to how we pre populate the array?

Regards,
Nitesh
- Original Message -
From: "John Fitzpatrick" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Sent: Thursday, June 02, 2005 6:00 PM
Subject: Re: Problem using indexed properties and validator framework




For an Array in a DynaForm property, you can either set the size in the
form-property descriptor or, in the case of a session form, pre-populate
the
Array in your action with the number of elements you desire.





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





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



RE: Regarding All

2005-06-05 Thread Vijaya S
In your action, store the result set in a bean of request or session scope
depending on your requirement. Use the bean in your jsp to display the
results using  tag.

Vijaya

-Original Message-
From: raja buddha [mailto:[EMAIL PROTECTED]
Sent: Sunday, June 05, 2005 9:38 AM
To: user@struts.apache.org
Subject: Regarding All


Hi all
 I am new to struts. Can any body know how to get the ResultSet
Objcet that is there in the Action Calls in to the View JSP.
My Question is i have write the DB aceess in the Action class in that class
my query returns a result set i need to loop the result set and display the
results in the view jsp

Thanks in advance

Raj

_
Express yourself instantly with MSN Messenger! Download today - it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/


-
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: Problems with tiles

2005-06-05 Thread David G. Friedman
Luke,

Your settings look normal.  I've checked the 1.2.4 code relating to your
error and somehow the struts initialization isn't loading or loading
correctly.   Have you turned on any sort of debugging and can show the
webapp startup messages?  Have you done any logging in your class to prove
it is loading?  Is your struts-config.xml spelled correctly, located in
/WEB-INF/struts-config.xml AND mentioned with the exact path in your
/WEB-INF/web.xml?

Regards,
David

-Original Message-
From: lk [mailto:[EMAIL PROTECTED]
Sent: Sunday, June 05, 2005 4:59 AM
To: Struts Users Mailing List
Subject: Re: Problems with tiles


David G. Friedman wrote:
> Luke,
>
> Can you include some of the code for your TilesRequestProcessor subclass
as
> well as how you initialize it in your struts-config.xml (or modules) ?
>
> Regards,
> David
>
> -Original Message-

Sure!

The CustomRequestProcessor is taken from a book by Mike Robinson:
^^
package com.mycompany.struts;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

//import org.apache.struts.action.RequestProcessor;
import org.apache.struts.tiles.TilesRequestProcessor;

/**
  * @author Mike Robinson
  *
  */
public class CustomRequestProcessor extends TilesRequestProcessor
{
/**
 * Handles validating of each user request, insuring that
 * the user has logged in properly. If not, they get re-directed
 * to the login page.
 */
protected boolean processPreprocess(HttpServletRequest request,

HttpServletResponse response)
{
boolean continueProcessing = true;

// Test if the request is a login request
try
{
HttpSession session = null;
// make sure session has not timed out
if(request.isRequestedSessionIdValid())
session = request.getSession();
else
response.sendRedirect("index.jsp?invalid=yes");

// get the current request path
String path = processPath(request, response);

// if user is not trying to logon or join, make sure 
user has been
authenticated
if ((!path.equals((String) "/index"))&&( 
!path.equals((String) "/join")))
{
// get the user bean
UserDTO user = (UserDTO) 
session.getAttribute("user");

// insure user has logged on
if (user == null)   // else make them logon 
first
{
try
{

response.sendRedirect("index.jsp?invalid=yes");
}
catch(Exception ioe)
{
log.error("problem redirecting 
in processPreprocess - " +
ioe.getMessage());
}
continueProcessing = false;
}
}
}
catch(Exception ioe)
{
log.error("problem processing path - " + 
ioe.getMessage());
continueProcessing = false;
}

return continueProcessing;
}
}

ì





 --
 Email.it, the professional e-mail, gratis per te: http://www.email.it/f

 Sponsor:
 Niente paura, da oggi puoi recuperare i dati persi dal PC, semplice come
cliccare qui
 Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid361&d=6

-
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: Validator html:errors returns null for {0}

2005-06-05 Thread Titus Barik

Titus Barik wrote:

But when I type an invalid e-mail address, in html:errors I always get:

null is an invalid e-mail address.


Figured it out. arg0 key refers to the key in the Properties file.

--
Titus Barik ([EMAIL PROTECTED])
http://www.barik.net

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



Validator html:errors returns null for {0}

2005-06-05 Thread Titus Barik

Hi all,

I'm trying to use the ValidatorForm feature of struts. I have a 
validation.xml:








which I've copied straight from the struts tutorial that validates an 
e-mail address.


I have a JSP page:

<%@ taglib uri="/tags/struts-html" prefix="html" %>
<%@ taglib uri="/tags/struts-bean" prefix="bean" %>
<%@ taglib uri="/tags/struts-logic" prefix="logic" %>




   

   


   






But when I type an invalid e-mail address, in html:errors I always get:

null is an invalid e-mail address.

What am I doing wrong? Am I missing a taglib?

Any help is greatly appreciated, as I can't figure this one out.

Thanks,

--
Titus Barik ([EMAIL PROTECTED])
http://www.barik.net

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



Re: help with messages using bean on jsp

2005-06-05 Thread Martin Gainty

Tony-
This is ok if you dont want to use locale-specific resource strings (you 
just want to display the non-locale specific string)
If you do want to use locale-specific resource strings (from your resource 
bundle) I would not use key="PutFullyQualfiedNameOfKeyHere" />

All the same I'm glad the former solution worked for you,
Martin-
- Original Message - 
From: "Tony Dahbura" <[EMAIL PROTECTED]>

To: "Martin Gainty" <[EMAIL PROTECTED]>
Cc: "Struts Users Mailing List" ; "Aman A" 
<[EMAIL PROTECTED]>

Sent: Sunday, June 05, 2005 3:22 PM
Subject: Re: help with messages using bean on jsp



All:
Figured out the problem:
My JSP page was trying to display the messages using the following code:

   
   



I should have used a   tag instead.  I think 
the  tag was trying to lookup the message as the key to a 
message rather than just displaying the message?


Thanks,
Tony


Martin Gainty wrote:


Tony-
to allow access by your Struts app's bean tag set the struts-config.xml

(ApplicationResources.properties is located in test folder off root)
Now you can have multiple identify the particular ApplicationResources implementation


You can use bean:message to pull the parameter and substitute your 
parameters in



But JSTL is better suited for internationalisation and message formatting 
so entering the bundle identifier in web.xml


 javax.servlet.jsp.jstl.fmt.localizationContext
 ApplicationResources


later on in your jsp
<%@ taglib uri=http://java.sun.com/jstl/fmt prefix="fmt"%>
and now do your substitution..
 where 
bundleToUse is ApplicationResources.properties
In this way all of your strings will be assigned to locale specific 
properties file


HTH,
Martin-
- Original Message - From: "Tony Dahbura" <[EMAIL PROTECTED]>
To: "Martin Gainty" <[EMAIL PROTECTED]>
Cc: "Struts Users Mailing List" 
Sent: Thursday, June 02, 2005 9:59 PM
Subject: Re: help with messages using bean on jsp


I do not have a ApplicationMessageResources_en_US.properties but I do 
have a ApplicationMessageResources.properties file with the following 
properties:

global.required={0} is a required value.

As can be seen the actual substitution is taking place.  I pass "userid" 
and it replaces the string with "userid is a required value"

so the substitution is working but the message is prepended with en_US

Any help would be appreciated it!

Tony


Martin Gainty wrote:


Tony-
More specifically you will need a
ApplicationMessageResources_en_US.property which would be located in 
web-inf\classes\tonyapp folder

where the property key value would display something like
userid=some_username
password=some_password
HTH,
Martin-
- Original Message - From: "Michael Jouravlev" 
<[EMAIL PROTECTED]>

To: "Struts Users Mailing List" 
Sent: Wednesday, June 01, 2005 9:28 PM
Subject: Re: help with messages using bean on jsp


Do you have ApplicationMessageResources.properties property file,
which is located in WEB-INF\classes\tonyapp ?

On 6/1/05, Tony Dahbura <[EMAIL PROTECTED]> wrote:


I have a peculiar problem cropping up with Struts 1.2.7...

When I add an actionError to using my form bean and then go to display
it in the html jsp page I get the following:

* ???en_US.userid is a required value.???
* ???en_US.password is a required value.???

My struts-config.xml file looks like this for the message resources:





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









-
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: What does it mean?

2005-06-05 Thread Martin Gainty

Andy-

More than likely the DTD you are using is messed up (in your web.xml) try
http://java.sun.com/dtd/web-app_2_2.dtd";>
feel free to email offline as this is decidedly 'off-topic'
(altho its sunday and most folks arent working we should still be respectful 
of being on topic)


HTH-
Martin

- Original Message - 
From: "Adam Hardy" <[EMAIL PROTECTED]>

To: "Struts Users Mailing List" 
Sent: Sunday, June 05, 2005 3:40 PM
Subject: Re: What does it mean?



It means you're on the wrong mailing list ;)

Taking a wild guess, I'd say you have a problem with the tag library 
definitions for JSTL (tld's). Depending on what version of tomcat (or 
rather, what servlet spec), you may have to put entries in your web.xml. 
Or you may be having problems accessing the net (in some situations a web 
server will fetch xml DTDs and schemas from the net).


Try mailing list archives for your webserver, or for JSTL / 
jakarta-taglibs, or even eclipse.


Adam

On 05/06/05 18:09 lk wrote:

Hi,

I got the following error:

Exception initializing TldLocationsCache: XML parsing error on file
/WEB-INF/tlds/sql.tld: (line 3, col 8): Document is invalid: no grammar
found.

I'm using MyEclipseIde 3.8.4 on Eclipse 3.0.2 (linux).

I get that exception many times during the running of my application and
I cannot understand what does it mean.

I don't use this tag in my application but the sql.tld is in the correct 
directory.


Thanks for any advise!

LuKe



-
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: What does it mean?

2005-06-05 Thread Adam Hardy

It means you're on the wrong mailing list ;)

Taking a wild guess, I'd say you have a problem with the tag library 
definitions for JSTL (tld's). Depending on what version of tomcat (or 
rather, what servlet spec), you may have to put entries in your web.xml. 
Or you may be having problems accessing the net (in some situations a 
web server will fetch xml DTDs and schemas from the net).


Try mailing list archives for your webserver, or for JSTL / 
jakarta-taglibs, or even eclipse.


Adam

On 05/06/05 18:09 lk wrote:

Hi,

I got the following error:

Exception initializing TldLocationsCache: XML parsing error on file
/WEB-INF/tlds/sql.tld: (line 3, col 8): Document is invalid: no grammar
found.

I'm using MyEclipseIde 3.8.4 on Eclipse 3.0.2 (linux).

I get that exception many times during the running of my application and
I cannot understand what does it mean.

I don't use this tag in my application but the sql.tld is in the correct 
directory.


Thanks for any advise!

LuKe



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



Re: Avoiding attacking server

2005-06-05 Thread Adam Hardy
If you really want to do it programmatically in your app you would have 
to write a filter which caches the IP addresses of the incoming 
requests. Check out any example filter you can find (they're normally 
quite basic) and configure it according to the docs on the tomcat site - 
it's standard j2ee.


On 05/06/05 15:26 Mark Benussi wrote:

Is it possible to set this in any other way as I don't have access to my
httpd.conf with my current hosts.

-Original Message-
From: Martin Gainty [mailto:[EMAIL PROTECTED] 
Sent: 05 June 2005 14:58

To: Struts Users Mailing List
Subject: Re: Avoiding attacking server

set your MaxClients directive (max number of simultaneously connected 
clients) in your httpd.conf

Take a look at
http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-apache-co
nfig.html
Anyone else ???
Martin-
- Original Message - 
From: "John Plate" <[EMAIL PROTECTED]>

To: "Struts Users Mailing List" 
Sent: Saturday, June 04, 2005 9:38 AM
Subject: Avoiding attacking server




Hi

Is it possible to configure how often an IP number can access the
Struts web-server? Fx, an attacking server may overwhelm the Struts
server with requests...

Thanks
John



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



Re: help with messages using bean on jsp

2005-06-05 Thread Tony Dahbura

All:
Figured out the problem:
My JSP page was trying to display the messages using the following code:

   
   



I should have used a   tag instead.  I think 
the  tag was trying to lookup the message as the key to a 
message rather than just displaying the message?


Thanks,
Tony


Martin Gainty wrote:


Tony-
to allow access by your Struts app's bean tag set the struts-config.xml

(ApplicationResources.properties is located in test folder off root)
Now you can have multiple identify the particular ApplicationResources implementation


You can use bean:message to pull the parameter and substitute your 
parameters in



But JSTL is better suited for internationalisation and message 
formatting so entering the bundle identifier in web.xml


 javax.servlet.jsp.jstl.fmt.localizationContext
 ApplicationResources


later on in your jsp
<%@ taglib uri=http://java.sun.com/jstl/fmt prefix="fmt"%>
and now do your substitution..
 where 
bundleToUse is ApplicationResources.properties
In this way all of your strings will be assigned to locale specific 
properties file


HTH,
Martin-
- Original Message - From: "Tony Dahbura" <[EMAIL PROTECTED]>
To: "Martin Gainty" <[EMAIL PROTECTED]>
Cc: "Struts Users Mailing List" 
Sent: Thursday, June 02, 2005 9:59 PM
Subject: Re: help with messages using bean on jsp


I do not have a ApplicationMessageResources_en_US.properties but I do 
have a ApplicationMessageResources.properties file with the following 
properties:

global.required={0} is a required value.

As can be seen the actual substitution is taking place.  I pass 
"userid" and it replaces the string with "userid is a required value"

so the substitution is working but the message is prepended with en_US

Any help would be appreciated it!

Tony


Martin Gainty wrote:


Tony-
More specifically you will need a
ApplicationMessageResources_en_US.property which would be located in 
web-inf\classes\tonyapp folder

where the property key value would display something like
userid=some_username
password=some_password
HTH,
Martin-
- Original Message - From: "Michael Jouravlev" 
<[EMAIL PROTECTED]>

To: "Struts Users Mailing List" 
Sent: Wednesday, June 01, 2005 9:28 PM
Subject: Re: help with messages using bean on jsp


Do you have ApplicationMessageResources.properties property file,
which is located in WEB-INF\classes\tonyapp ?

On 6/1/05, Tony Dahbura <[EMAIL PROTECTED]> wrote:


I have a peculiar problem cropping up with Struts 1.2.7...

When I add an actionError to using my form bean and then go to display
it in the html jsp page I get the following:

* ???en_US.userid is a required value.???
* ???en_US.password is a required value.???

My struts-config.xml file looks like this for the message resources:





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









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



Re: Problems with

2005-06-05 Thread Martin Gainty

Peceka
Looks like something simple like
localhost isnt defined in your hosts file
What do the tomcat logs say??
Martin-

- Original Message - 
From: "peceka" <[EMAIL PROTECTED]>

To: 
Sent: Sunday, June 05, 2005 11:15 AM
Subject: Problems with 


Hi,

My simple aplication:
register1.jsp
register.do:

(from struts-config.xml):

 

and results1.jsp

It works.
But when i add to my struts-config.xml:


   
   
   
   
   
   
   
   




My application doesn't work. With my brwoser I go to register1.jsp
then submit my form and in browser i've got:

HTTP Status 404 - Servlet action is not available

type Status report

message Servlet action is not available

description The requested resource (Servlet action is not available)
is not available.
Apache Tomcat/5.5.7


I'm using struts 1.2.7, jdk1.5, netbeans 4.1 (with tomcat5.5).


Why? What's wrong with this?
I've added library commons-dbcp-1.2.1.jar to my project and of course:
postgresql-8.0-311.jdbc3.jar.


TIA,
pecek.

-
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: Regarding All

2005-06-05 Thread raja buddha

HI Deepak,
  If you have code can you please send me. It will be great help for me

Thanks in advance

Prem


From: Kumar deepak <[EMAIL PROTECTED]>
Reply-To: "Struts Users Mailing List" 
To: Struts Users Mailing List 
Subject: Re: Regarding All
Date: Sat, 4 Jun 2005 22:30:02 -0700 (PDT)

Hi,

You can add the Resultset data into a java bean and then set the Bean in 
the request object and then use in jsp page.


Regards
Deepak Kumar


raja buddha <[EMAIL PROTECTED]> wrote:
Hi all
I am new to struts. Can any body know how to get the ResultSet
Objcet that is there in the Action Calls in to the View JSP.
My Question is i have write the DB aceess in the Action class in that class
my query returns a result set i need to loop the result set and display the
results in the view jsp

Thanks in advance

Raj

_
Express yourself instantly with MSN Messenger! Download today - it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/


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



-
Discover Yahoo!
 Find restaurants, movies, travel & more fun for the weekend. Check it 
out!


_
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/



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



What does it mean?

2005-06-05 Thread lk

Hi,

I got the following error:

Exception initializing TldLocationsCache: XML parsing error on file
/WEB-INF/tlds/sql.tld: (line 3, col 8): Document is invalid: no grammar
found.

I'm using MyEclipseIde 3.8.4 on Eclipse 3.0.2 (linux).

I get that exception many times during the running of my application and
I cannot understand what does it mean.

I don't use this tag in my application but the sql.tld is in the correct 
directory.


Thanks for any advise!

LuKe





--

Email.it, the professional e-mail, gratis per te: http://www.email.it/f



Sponsor:

Solo 10 Euro per chiamare in tutto il mondo!! Scopri il vantaggio di Email 
Phone Card,clicca subito

Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=2685&d=5-6

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



Problems with

2005-06-05 Thread peceka
Hi,

My simple aplication:
register1.jsp
register.do:

(from struts-config.xml):

  

and results1.jsp

It works.
But when i add to my struts-config.xml:














My application doesn't work. With my brwoser I go to register1.jsp
then submit my form and in browser i've got:

HTTP Status 404 - Servlet action is not available

type Status report

message Servlet action is not available

description The requested resource (Servlet action is not available)
is not available.
Apache Tomcat/5.5.7


I'm using struts 1.2.7, jdk1.5, netbeans 4.1 (with tomcat5.5).


Why? What's wrong with this?
I've added library commons-dbcp-1.2.1.jar to my project and of course:
postgresql-8.0-311.jdbc3.jar.


TIA,
pecek.

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



RE: Avoiding attacking server

2005-06-05 Thread Mark Benussi
Is it possible to set this in any other way as I don't have access to my
httpd.conf with my current hosts.

-Original Message-
From: Martin Gainty [mailto:[EMAIL PROTECTED] 
Sent: 05 June 2005 14:58
To: Struts Users Mailing List
Subject: Re: Avoiding attacking server

set your MaxClients directive (max number of simultaneously connected 
clients) in your httpd.conf
Take a look at
http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-apache-co
nfig.html
Anyone else ???
Martin-
- Original Message - 
From: "John Plate" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Sent: Saturday, June 04, 2005 9:38 AM
Subject: Avoiding attacking server


> Hi
>
> Is it possible to configure how often an IP number can access the
> Struts web-server? Fx, an attacking server may overwhelm the Struts
> server with requests...
>
> Thanks
> John
>
>
> -
> 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]


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



Re: Avoiding attacking server

2005-06-05 Thread Martin Gainty
set your MaxClients directive (max number of simultaneously connected 
clients) in your httpd.conf

Take a look at
http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-apache-config.html
Anyone else ???
Martin-
- Original Message - 
From: "John Plate" <[EMAIL PROTECTED]>

To: "Struts Users Mailing List" 
Sent: Saturday, June 04, 2005 9:38 AM
Subject: Avoiding attacking server



Hi

Is it possible to configure how often an IP number can access the
Struts web-server? Fx, an attacking server may overwhelm the Struts
server with requests...

Thanks
John


-
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: Problems with tiles

2005-06-05 Thread lk

David G. Friedman wrote:

Luke,

Can you include some of the code for your TilesRequestProcessor subclass as
well as how you initialize it in your struts-config.xml (or modules) ?

Regards,
David

-Original Message-


Sure!

The CustomRequestProcessor is taken from a book by Mike Robinson:
^^
package com.mycompany.struts;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

//import org.apache.struts.action.RequestProcessor;
import org.apache.struts.tiles.TilesRequestProcessor;

/**
 * @author Mike Robinson
 *
 */
public class CustomRequestProcessor extends TilesRequestProcessor
{
/**
 * Handles validating of each user request, insuring that
 * the user has logged in properly. If not, they get re-directed
 * to the login page.
 */
protected boolean processPreprocess(HttpServletRequest request,

HttpServletResponse response)
{
boolean continueProcessing = true;

// Test if the request is a login request
try
{
HttpSession session = null;
// make sure session has not timed out
if(request.isRequestedSessionIdValid())
session = request.getSession();
else
response.sendRedirect("index.jsp?invalid=yes"); 
  

// get the current request path
String path = processPath(request, response);

			// if user is not trying to logon or join, make sure user has been 
authenticated

if ((!path.equals((String) "/index"))&&( !path.equals((String) 
"/join")))
{
// get the user bean
UserDTO user = (UserDTO) 
session.getAttribute("user");

// insure user has logged on
if (user == null)   // else make them logon 
first
{
try
{

response.sendRedirect("index.jsp?invalid=yes"); 
  
}
catch(Exception ioe)
{
		log.error("problem redirecting in processPreprocess - " + 
ioe.getMessage());

}
continueProcessing = false;
}
}
}
catch(Exception ioe)
{
log.error("problem processing path - " + 
ioe.getMessage());
continueProcessing = false;
}

return continueProcessing;
}
}

ì







--

Email.it, the professional e-mail, gratis per te: http://www.email.it/f



Sponsor:

Niente paura, da oggi puoi recuperare i dati persi dal PC, semplice come 
cliccare qui

Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid361&d=5-6

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