RE: No Context Configured to Process this request

2002-10-06 Thread K Br

can you clarify? I thought you are passing the full path
(/popUp) as the parameter?

THank you

/Kobe


On Sun, 6 Oct 2002 15:24:56 +0530  Divakar Satyanarayan [EMAIL PROTECTED] 
wrote:
Hi,

 I resolved this .. I had to pass the full path when I am passing action as
a paramter ..

Regards,
Divakar

 -Original Message-
 From:Divakar Satyanarayan [SMTP:[EMAIL PROTECTED]]
 Sent:Sunday, October 06, 2002 1:34 PM
 To:  'Struts Users Mailing List'
 Subject: No Context Configured to Process this request
 
 Hi ,
 
   I have a pop up window that opens when the user clicks on a button. I
 have
 made use of the action parameter/popUp to be sent as the URL. I have
 defined a forward for the action in my struts-config.xml.
 
  Below is my content of my struts-config.
 
  form-beans
  form-bean name=messageForm  type=messageInputForm
  /form-bean
  /form-beans
  action-mappings
  action path=/display
  type=messageInputAction
  name=messageForm
  forward name=success
   path=/jsp/DisplayMessage.jsp
   redirect=false
  /forward
  /action
  action path=/popUp
  forward=/jsp/modalInput.jsp
  /action
  /action-mappings
   
 
  This is the code where I am passing the action as a parameter to open new
 window
 
 html:button value=Open Window property=message onclick =
 javascript:openAdvSrcWindow('/popUp')/
 
  but when I click on the button I get the following error 
 
   HTTP 500 - No context configured to process this request. What is it
 that
 I doing wrong here ?
 
  Please do give in ur suggestion.
 
 Thanks in Advance,
 Divakar   
 
 
 DISCLAIMER: Information contained and transmitted by this E-MAIL is
 proprietary to Mascot Systems Limited and is intended for use only by the
 individual or entity to which it is addressed, and may contain information
 that is privileged, confidential or exempt from disclosure under
 applicable
 law. If this is a forwarded message, the content of this E-MAIL may not
 have
 been sent with the authority of the Company. If you are not the intended
 recipient, an agent of the intended recipient or a person responsible for
 delivering the information to the named recipient, you are notified that
 any
 use, distribution, transmission, printing, copying or dissemination of
 this
 information in any way or in any manner is strictly prohibited. If you
 have
 received this communication in error, please delete this mail  notify us
 immediately at [EMAIL PROTECTED] Before opening attachments,
 please scan for viruses. 
 
 
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 
DISCLAIMER: Information contained and transmitted by this E-MAIL is
proprietary to Mascot Systems Limited and is intended for use only by the
individual or entity to which it is addressed, and may contain information
that is privileged, confidential or exempt from disclosure under applicable
law. If this is a forwarded message, the content of this E-MAIL may not have
been sent with the authority of the Company. If you are not the intended
recipient, an agent of the intended recipient or a person responsible for
delivering the information to the named recipient, you are notified that any
use, distribution, transmission, printing, copying or dissemination of this
information in any way or in any manner is strictly prohibited. If you have
received this communication in error, please delete this mail  notify us
immediately at [EMAIL PROTECTED] Before opening attachments,
please scan for viruses. 



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




Specifying button-specific actions in a form

2002-10-06 Thread K Br

I have a form with three commands (add, delete and logout). It appears to me that I 
must forward them
to a single action and conveying the specific
operation using a property as in:

 html:form method=GET action=processCommand.do
 //...
 html:submit property=action value=Add /
 html:submit property=action value=Delete /
 html:submit property=action value=Logout /
 /html:form

I would like to make the JSP more readable by
specifying distinct actions to distinct buttons:
   Add - /performAdd.do
   Delete - /performDelete.do
   Logout - /logout.do

(these actions may be implemented by the same
Action class, but that's hidden from the JSP 
author).

Is there a way to do this?
 
Tx,

/Kobe



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




Re: Specifying button-specific actions in a form

2002-10-06 Thread K Br

DispatchAction works fine. Thanks.

However I need to submit different ActionForms
with different subactions in

 html:form ...
   html:submit ...add...
   html:submit ...delete...
   ...

Since DispatchAction multiplexes different
subactions using the same action mapping
entry, it will use the same ActionForm.

The other way is to define distinct action mappings 
for different subactions (add, delete, ...) and
specify different form beans for each entry in
struts-config.

I prefer to use DIspatchAction, as I think its neater.
Is there a way for me to tell DispatchAction to
use different forms beans for different methods?

Tx

/Kobe


On Sun, 6 Oct 2002 16:16:27 +0200 (CEST) Pavel Kolesnikov [EMAIL PROTECTED] wrote:
On 6 Oct 2002, K Br wrote:

 I would like to make the JSP more readable by
 specifying distinct actions to distinct buttons:
Add - /performAdd.do
Delete - /performDelete.do
Logout - /logout.do
 
 (these actions may be implemented by the same
 Action class, but that's hidden from the JSP 
 author).

@see org.apache.struts.actions.DispatchAction

pavel




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




Re: Using friendly names for application entry points

2002-10-05 Thread K Br

Thanks for the responses. That was indeed the problem.

/Kobe

On Fri, 4 Oct 2002 17:39:41 -0400 Dave Derry [EMAIL PROTECTED] wrote:
Tryhtml:form action=performLogin.do method=GET
Notice the '.do'; it has to do with the servlet mapping. You apparently have
*.do mapped to the the Struts ActionServlet, but Jasper doesn't know what to
do with performLogin.

Dave Derry


- Original Message -
From: K Br [EMAIL PROTECTED]


 The husted Struts site recommends that all application
 entry points be given friendly names using the
 global-forwards mapping table. Following this advice,
 I converted

html:form action=/login.do method=GET
   //...
/html:form

 to

html:form action=performLogin method=GET
   //...
/html:form

 by adding the global-forwards entry


   global-forwards
 forward name=performLogin path=/login.do/
 //...
   /global-forwards

 I thought this made my JSP friendlier but I get the
 Jasper exception:

 org.apache.jasper.JasperException: Cannot retrieve mapping for action
/performLogin

 What am I missing?

 /Kobe



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




Using friendly names for application entry points

2002-10-04 Thread K Br

The husted Struts site recommends that all application
entry points be given friendly names using the
global-forwards mapping table. Following this advice,
I converted

   html:form action=/login.do method=GET
  //...
   /html:form

to

   html:form action=performLogin method=GET
  //...
   /html:form

by adding the global-forwards entry


  global-forwards
forward name=performLogin path=/login.do/
//...
  /global-forwards

I thought this made my JSP friendlier but I get the
Jasper exception:

org.apache.jasper.JasperException: Cannot retrieve mapping for action /performLogin

What am I missing?

/Kobe







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




Handling submit with multibox

2002-05-15 Thread K Br

i have a form that lists a number of items using logic:iterate
and makes each item selectable using a check box (multibox).


 logic:iterate id=currBook collection=%= books %
   tr
td
html:multibox property=books
   bean:write name=currBook property=title/
/html:multibox
bean:write name=currBook property=title/
/td
   br/
   /tr
 /logic:iterate

The associated Form object makes available an item array Book[]
as a property that should contain the selected items. The submit button 
triggers an action that deletes the ietms from the Form's
Book[] array from the database. 

Upon pressing the submit button, I get the following server 
internal error:

javax.servlet.ServletException: BeanUtils.populate
at org.apache.struts.util.RequestUtils.populate(RequestUtils.java:774)
at org.apache.struts.action.ActionServlet.processPopulate(ActionServlet.
java:2061)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:156
4)
at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492)
[ ... ]


what does this error mean?

Tx,

/Kobe




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




implementing form actions

2002-05-15 Thread K Br

what is the recommended action structure
to implement the following form pattern?

  [data fields]
 [operation1] [operation2]...[operationN]

I currently define a single action, forward
all the [operation] buttons to the action and let
the action distinguish between the various operations
based on a property name. 

is this the only approach
or is there a better approach.

Tx

/Kobe



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




Puzzling error with logic:iterate

2002-05-09 Thread K Br

pl help. i have been wracking my small brain over this
for a few hours and i have no clew.

i am using logic:iterate copybook style; yet, it throws the runtime exception:

javax.servlet.ServletException: Cannot find bean currBook in scope null

the iterate statement is:
logic:iterate id=currBook collection=%= books %
   Next book: bean:write name=currBook property=title/
 /logic:iterate
 


the complete source is:


%@ page language=java import=My.*
 import=java.util.* %
%@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean %
%@ taglib uri=/WEB-INF/struts-html.tld prefix=html %
%@ taglib uri=/WEB-INF/struts-logic.tld prefix=login %

html:html locale=true
  head
html:base /
html:errors /
/head

  body
   % 
My.Book[] books = new My.Book[4];
books[0] = new Book(An Introduction to Algebra, 100);
books[1] = new Book(JSP: An Advanced Course, 234);
books[2] = new Book(JavaScript and JSP Pages, 333);
 System.out.println(Books =  + books);
pageContext.setAttribute(books, books, PageContext.PAGE_SCOPE);

   %

   html:form method=GET action=addBook.do

 logic:iterate id=currBook collection=%= books %
   Next book: bean:write name=currBook property=title/
 /logic:iterate
 html:submit//td
   /html:form
   p
  /body
/html:html





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