html - 如何删除 2 个单词之间的大空间以证明移动设备中的对齐方式?

标签 html css

enter image description here我使用了 text-align: justify; 但有时它会在两个单词之间显示较大的 space 。这就是为什么我尝试为移动设备解决它并使用 text-justify: inter-word; 来删除空间但它不起作用。

@media screen and (max-width: 640px) {

.mobile-con{text-align: justify !important;文本对齐:词间;

HTML

<p style="text-align: justify;" class="mobile-con">
                           Star aims to be the world class consortium of choice by
                            delivering projects within time & budget and to the 
                            required standards of quality by the fusion & best
                            application of human intellect & ethics with the 
                            combination of modern technology. 

                        </p>

我该如何解决?

最佳答案

使用 word-break: break-all; 将所有单词打断以适应定义的宽度。

关于html - 如何删除 2 个单词之间的大空间以证明移动设备中的对齐方式?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51188156/

相关文章:

php - Polymer,使用ajax形式发送图片

php - Wordpress - get_search_form() 与图标在同一行

html - 如何从 HTML 表格代码中删除/剥离所有格式或样式信息?

javascript - 无法通过 JavaScript 检查复选框

html - 如何将链接制作为水平 block ?

jquery - 在下拉菜单中单击时升起选中的单选按钮

javascript - CSS:除正方形外的模糊背景

css - 在CSS flip中,TransformZ元素不在最上面

java - 使用套接字时在 HTML 页面中嵌入 Java JApplet

html - 仅为移动设备删除页脚