ShowStyleName.java
资源名称:shihua.rar [点击查看]
上传用户:zghglow
上传日期:2022-08-09
资源大小:27227k
文件大小:2k
源码类别:
WEB源码(ASP,PHP,...)
开发平台:
JavaScript
- package com.chinacannel.xlchemical.Tag;
- import javax.servlet.jsp.tagext.*;
- import javax.servlet.jsp.JspException;
- import javax.servlet.jsp.JspWriter;
- public class ShowStyleName extends TagSupport {
- private Long style;
- public Long getStyle() {
- return style;
- }
- public void setStyle(Long style) {
- this.style = style;
- }
- public int doStartTag() throws JspException {
- String name = "";
- try {
- JspWriter out = pageContext.getOut();
- String Language = "";
- if (this.pageContext.getSession().getAttribute("Language") != null) {
- Language = this.pageContext.getSession().getAttribute(
- "Language").toString();
- }
- if (this.getStyle().equals(new Long(1))) {
- if (Language.equals("CN")) {
- name = "企业信息";
- } else {
- name = "Profile";
- }
- } else if (this.getStyle().equals(new Long(2))) {
- if (Language.equals("CN")) {
- name = "企业文化";
- } else {
- name = "Culture";
- }
- } else if (this.getStyle().equals(new Long(3))) {
- if (Language.equals("CN")) {
- name = "新闻公告";
- } else {
- name = "News Notice";
- }
- } else if (this.getStyle().equals(new Long(4))) {
- if (Language.equals("CN")) {
- name = "股东天地";
- } else {
- name = "Partners";
- }
- } else if (this.getStyle().equals(new Long(5))) {
- if (Language.equals("CN")) {
- name = "生产经营";
- } else {
- name = "Product";
- }
- } else if (this.getStyle().equals(new Long(6))) {
- if (Language.equals("CN")) {
- name = "人力资源";
- } else {
- name = "Human Resource";
- }
- }
- out.print(name);
- } catch (Exception e) {
- throw new JspException(e);
- }
- return 0;
- }
- }