码迷,mamicode.com
首页 > 其他好文 > 详细

freemarker中间split字符串切割

时间:2015-12-09 11:34:04      阅读:410      评论:0      收藏:0      [点我收藏+]

标签:

freemarker中间split字符串切割


1、简易说明

     split切割:用来依据另外一个字符串的出现将原字符串切割成字符串序列


2、举例说明

<#--freemarker中的split字符串切割-->
     <#list "张三三,李思思,,王强,柳树,诸葛正我"?

split(",") as name> "${name}" </#list> <#list "AhuAjiuAjkdsfAoionAjiuiAnujkkdfAkoijAmcjdhfjdfaAdhnfjdhfA"?

split("A") as num> "${num}" </#list>


3、演示样例结果

<span style="white-space:pre">	</span> "张三三"
         "李思思"
         ""
         "王强"
         "柳树"
         "诸葛正我"
     
         ""
         "hu"
         "jiu"
         "jkdsf"
         "oion"
         "jiui"
         "nujkkdf"
         "koij"
         "mcjdhfjdfa"
         "dhnfjdhf"
         ""


freemarker中间split字符串切割

标签:

原文地址:http://www.cnblogs.com/gcczhongduan/p/5031947.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!