gpt4 book ai didi

html - 如何将文本移动到框的末尾?

转载 作者:行者123 更新时间:2023-11-27 23:21:47 27 4
gpt4 key购买 nike

我创建了两个 flex 盒子。左侧的框显示图像。右侧的框显示文本,但必须显示在框的末尾。

.Details {
background-color: yellow;
display: inline;
}

p span {
background-color: yellow;
}

.End {
display: inline;
}

.End {
display: flex;
}

.End.img {
justify-content: left;
}

.End.p {
justify-content: right;
}
<div class="End">
<img src="http://www.intro-webdesign.com/images/newlogo.png">
<div id="BLOCK">
<p>This page was created by <span class="MyName">nameh dhreh</span> and Colleen Van Lent.To learn more about web design, visit <a href="http://www.intro-webdesign.com">Intro To Web Design</a>.</p>
</div>
</div>

最佳答案

如果您的意思是将文本对齐到“框的末端” -

.Details {
background-color: yellow;
display: inline;
}

p span {
background-color: yellow;
}

.End {
display: inline;
}

.End {
display: flex;
}

.End.img {
justify-content: left;
}

.End.p {
justify-content: right;
}

#BLOCK {
text-align: right;
}
<div class="End">
<img src="http://www.intro-webdesign.com/images/newlogo.png">
<div id="BLOCK">
<p>This page was created by <span class="MyName">Madiha Gurchani</span> and Colleen Van Lent.To learn more about web design, visit <a href="http://www.intro-webdesign.com">Intro To Web Design</a>.</p>
</div>
</div>

关于html - 如何将文本移动到框的末尾?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57956278/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com