textformat函数

textformat函数

表格属性:

微信图片_20180313125004.png

该函数主要清理空格和特殊字符,对段落按单词边界换行和行缩进等段落格式化处理.

用户可以明确设置各参数,或使用预处理风格. 目前只有唯一可用风格"email".

eg:

{textformat wrap=40}

This is foo.
This is foo.
This is foo.
This is foo.
This is foo.
This is foo.

This is bar.

bar foo bar foo foo.
bar foo bar foo foo.
bar foo bar foo foo.
bar foo bar foo foo.
bar foo bar foo foo.
bar foo bar foo foo.
bar foo bar foo foo.

{/textformat}

输出:
This is foo. This is foo. This is foo.
This is foo. This is foo. This is foo.

This is bar.

bar foo bar foo foo. bar foo bar foo
foo. bar foo bar foo foo. bar foo bar
foo foo. bar foo bar foo foo. bar foo
bar foo foo. bar foo bar foo foo.

继续学习
||
提交 重置代码
关于我们 免责声明 Sitemap
PHP中文网:公益在线PHP培训,帮助PHP学习者快速成长!