File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes <c:url param passes null always Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "<c:url param passes null always " Watch "<c:url param passes null always " New topic
Author

<c:url param passes null always

Abdul Wahab
Ranch Hand

Joined: Dec 09, 2011
Posts: 49

Hi all,
I am finding difficult to pass parameter value from one jsp to another in my struts application. Below are my code


Whenever i click the link . It Shows contactno always null

http://localhost:8080/Elclass/Prf/insertprfArticle.do?contractno=&action=insertArticle.

Can you please point out where i am wrong?

As long as breath left in my body there is hope
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61761
    
  67

DO you mean null, or empty? They're not the same thing.

In your URL, the value of the parameter is empty.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Abdul Wahab
Ranch Hand

Joined: Dec 09, 2011
Posts: 49

Hi bear,
Sorry. It shows empty. Contract No value is set using Agent dropdown list. Below are the code for reference
Abdul Wahab
Ranch Hand

Joined: Dec 09, 2011
Posts: 49

hi,
I tried passing other values still it shows empty. Only constant values (hard coded vales) are accepting.
Guess there might be some issues with my form bean or struts config file. i have attache by form bean and


struts config file

Here /saveprf action to save Prf.jsp. /Prf/insertprfArticle action to call PrfArticle.jsp . To call this page i am using <c:url>
Abdul Wahab
Ranch Hand

Joined: Dec 09, 2011
Posts: 49

hi,
Still confused why the value shows empty . any help on this will be great
Abdul Wahab
Ranch Hand

Joined: Dec 09, 2011
Posts: 49

hi all,
Still unable to find the solution. i created a seperate action (i am using Dispatch action here), to load the form and when i
reloaded the form the url parameter values are passed from one page to another. seems strange
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: <c:url param passes null always