注意,实现的方法必须是静态的
<%...@ taglib uri=" http://hxex.cn/vote " prefix="vote" %>
${vote.nama
${vote.title
${vote:votetype(vote.votetype)}
${vote:pictype(vote.pictype)}
修改投票
删除投票
修改选项
xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance "
xsi:schemaLocation=" http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-jsptaglibrary_2_0.xsd "
versi="2.0">
paket cn.hxex.vote.util;
Fungsi Vote kelas publik ...{
jenis suara String statis publik(Jenis suara string)...{
kembalikan SelectConst.getVoteTypeTitle(votetype);
}
opsi tipe suara String statis publik(String defaultValue)...{
kembalikan SelectConst.getVoteTypeOptions(defaultValue);
}
tipe gambar String statis publik(Jenis gambar string)...{
kembalikan SelectConst.getPicTypeTitle(pictype);
}
public static String pictypeoptions(String defaultValue)...{
kembalikan SelectConst.getPicTypeoptions(defaultValue);
}
}
http://blog.csdn.net/daryl715/archive/2007/02/11/1507387.aspx