缩短文本块中的单词 [英] shorten a word in a block of text

查看:33
本文介绍了缩短文本块中的单词的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个文本块,它偶尔有一个非常长的词/网址,它会超出我网站的布局.

I have a block of text which occasionally has a really long word/web address which breaks out of my site's layout.

浏览此文本块并缩短单词的最佳方法是什么?

What is the best way to go through this block of text and shorten the words?

示例:

这是一段文字,这是一个很长的词,看起来像这样

this is some text and this a long word appears like this

fkdfjdksodifjdisosdidjsosdifosdfiosdfoisjdfoijsdfoijsdfoijsdfoijsdfoijsdfoisjdfoisdjfoisdfjosdifjosdifjosdifjosdifjosdifjsodifjosdifjosidjfosdifjsdoiofsij and i need that to either wrap in ALL browsers or trim the word.

推荐答案

您需要 wordwrap 功能我想.

You need wordwrap function i suppose.

这篇关于缩短文本块中的单词的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆