如何使用 CSS 移动网站中的元素

问题描述 投票:0回答:1

我需要使用什么才能使我的网站中的按钮向左移动。我尝试使用不同的属性来移动我的按钮,我也尝试搜索答案,但没有答案有明确的解释。ssssssssssssssssssssssssssssssssssssss

php html css web
1个回答
0
投票

通过设置负值,margin-left 属性还可用于将元素向左移动。例如,以下 CSS 代码会将元素向左移动 100 像素:

element {margin-left: -100px;}
© www.soinside.com 2019 - 2024. All rights reserved.