Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

tag

fmt:setBundle tag

JSP Standard Label LibraryJSP Standard Tag Library

fmt:setBundleThe tag is used to load a resource bundle and then store it in a named variable in a scope or in the bundle configuration variable.

Syntax format





property

fmt:setBundleThe tag has the following attributes:

property Description Whether it is required Default value
basename The base name of the resource bundle family, exposed to the scope variable or configuration variable Is None
var The variable that stores the new resource bundle No Replace default
scope The scope of the variable No Page

Example Demonstration



<%@ page language="java" contentType="text/html; charset=UTF-8"

    pageEncoding="UTF-8"%>

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>





JSTL fmt:setBundle 标签
















The running result is as follows:



One 

Two 

Three


JSP Standard Label LibraryJSP Standard Tag Library