R
Rick DeBay
JSTL doesn't see "name" as a valid property for c:set, but cut has no problem
printing it. Any ideas? Tomcat 5.0.16 w/ JSTL 1.1
exception:
javax.servlet.ServletException: Invalid property in <set>: "name"
JSTL:
<cut value="${onlineCategory.name}"/>
<c:set target="onlineCategory" property="name" value=""/>
class:
//hack to display fixed categories until back end is working
import java.util.*;
public class Category
{
public int ID;
public String name;
public List subCategories = new ArrayList();
public Category(int ID, String name)
{
this.ID = ID;
this.name = name;
}
public void addSubCategory(Category c)
{
subCategories.add(c);
}
public int getID() {return ID;}
public String getName() {return name;}
public List getSubCategories() {return subCategories;}
public void setID(int id) {ID = id;}
public void setName(String n) {name = n;}
}
printing it. Any ideas? Tomcat 5.0.16 w/ JSTL 1.1
exception:
javax.servlet.ServletException: Invalid property in <set>: "name"
JSTL:
<cut value="${onlineCategory.name}"/>
<c:set target="onlineCategory" property="name" value=""/>
class:
//hack to display fixed categories until back end is working
import java.util.*;
public class Category
{
public int ID;
public String name;
public List subCategories = new ArrayList();
public Category(int ID, String name)
{
this.ID = ID;
this.name = name;
}
public void addSubCategory(Category c)
{
subCategories.add(c);
}
public int getID() {return ID;}
public String getName() {return name;}
public List getSubCategories() {return subCategories;}
public void setID(int id) {ID = id;}
public void setName(String n) {name = n;}
}