<foreach item="item" index="index" collection="str.split(',')" open="(" separator="," close=")">#{item}</foreach> 这里调用了java的split方法,把str分成了一个数组. 相关文章: 2021-12-12 2022-02-11 2021-04-08 2021-09-11 2022-12-23