wood burning stoves 2.0*
The moose likes JSP and the fly likes how to use tag?" title="" /> Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "how to use "property" attribute in <jsp:getProperty ....   /> tag?" Watch "how to use "property" attribute in <jsp:getProperty ....   /> tag?" New topic
Author

how to use "property" attribute in <jsp:getProperty .... /> tag?

shivam singhal
Ranch Hand

Joined: Jul 15, 2012
Posts: 226

what should be the value of property in getProperties tag in this Work.java file
that is
<jsp:getProperty name="Work" property="====" />

package com.example.web;

public class Work{
private String wrk;
public void setjob(String wrk1){
this.wrk=wrk1;
}
public String getjob(){
return wrk;
}
}


on what basis value of property tag is decided??
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61104
    
  66

==== is not a valid property name.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
shivam singhal
Ranch Hand

Joined: Jul 15, 2012
Posts: 226

offcourse === is not a property name...

m just asking about what should be written in the property attribute of getProperty tag??
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61104
    
  66

First, you need to fix the bean. setjob() and get job() are not correct; should be setJob() and getJob(). In that case, the proeprty name is job. Case is very important when dealing with beans.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to use "property" attribute in <jsp:getProperty .... /> tag?