<div dir="ltr" style="text-align: left;" trbidi="on">
<div dir="ltr" style="text-align: left;" trbidi="on">JSTL Parse Number tag is used to parse the numbers, percentage or currency. </p>
<p> <b>JSTL Parse Number Example:</b></p>
<pre class="highlight" name="code"><;%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>;
<;%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>;

<;html>;
<;head>;
 <;title>;JSTL Parse Number Example<;/title>;
<;/head>;
<;body>;
 <;!-- Setting Locale to US -->;
 <;fmt:parseNumber value="156.1432" var="test" integerOnly="TRUE" type="NUMBER">;<;/fmt:parseNumber>;
 <;c:out value="${test}">;<;/c:out>;
<;/body>;
<;/html>;
</pre>
<p></p>
<div class="separator" style="clear: both; text-align: center;"><img border="0" src="http://50.87.249.200/~dineshon/wp-content/uploads/2013/10/22222.png" /></div>
<p>
As you can see above, JSTL Parse Number Tag is used to parse the number. Parse Number Tag in JSTL has following attributes.</p>
<p> <b>1. value :</b> Value attribute provides the number to be parsed.</p>
<p> <b>2. type: </b>Type attribute specifies the type of string to be parsed. It can be NUMBER, PERCENT or CURRENCY.</p>
<p> <b>3. var </b>: Var attribute provides the variable that is used to store the parsed number. This variable can be used later in the jsp.</p>
<p> <b>4. intgerOnly: </b>integerOnly attribute allows to store number in Integer format only. Default value is false.</p>
<p> <b>5. pattern:</b> Pattern attribute provides custom formatting pattern that determines how the string in the value attribute is to be parsed.</p>
<p> <b>6. scope:</b> Scope attribute provides the scope of variable.</div>
<div style="background-color: pink; border-width: thin; text-align: center;"><b><;<;<a href="https://dineshonjava.com/2013/10/jstl-formatnumber-tag.html">Previous</a> <;<; ; ; || <a href="https://dineshonjava.com/2013/10/jsp-standard-tag-library-jstl-tutorial.html">Index </a>||  ; >;>;<a href="https://dineshonjava.com/2013/10/jstl-parsedate-formatdate-example.html">Next</a> >;>;</b></div>
</div>
<div class="wp-post-navigation"> 
									 <div class="wp-post-navigation-pre"> 
									 <a href="https://dineshonjava.com/jstl-formatnumber-tag/">Previous</a> 
									 </div> 
									 <div class="wp-post-navigation-next"> 
									 <a href="https://dineshonjava.com/jstl-parsedate-formatdate-example/">Next</a> 
									 </div> 
									</div>
<script type="text/javascript">
jQuery(document).ready(function($) {
 $.post('https://dineshonjava.com/wp-admin/admin-ajax.php', {action: 'mts_view_count', id: '306'});
});
</script>
Strategy Design Patterns We can easily create a strategy design pattern using lambda. To implement…
Decorator Pattern A decorator pattern allows a user to add new functionality to an existing…
Delegating pattern In software engineering, the delegation pattern is an object-oriented design pattern that allows…
Technology has emerged a lot in the last decade, and now we have artificial intelligence;…
Managing a database is becoming increasingly complex now due to the vast amount of data…
Overview In this article, we will explore Spring Scheduler how we could use it by…