我在我的网站主页上放置了一个图像,但是我想要移动图像的位置而不是操纵图像的像素。我确定它与填充或边距有关,但我不确定如何将其实施到我的程序中。这是我的代码:如何移动图片的位置?
<!doctype html>
<html>
<head>
<link rel="stylesheet" type="text/css" href="stylesheetMain.css">
<title> Main Page </title>
</head>
<body>
<!-- This is the image I want to move around! -->
<img src="blake.jpg" alt="Mountain View" style="width:141px;height:114px;">
<div class="link1" onclick="location.href='';" style="cursor: pointer;">
</div>
<div class="link2" onclick="location.href='ImagePage.html';" style="cursor: pointer;">
</div>
<div class="link3" onclick="location.href='gamequiz.html';" style="cursor: pointer;">
</div>
<div class="link4" onclick="location.href='orderform.html';" style="cursor: pointer;">
</div>
<div class="link5" onclick="location.href='comments.html';" style="cursor: pointer;">
</div>
<div class="link6" onclick="location.href='';" style="cursor: pointer;"><br><br><br>
Author: Michael Cattermole
</div>
</body>
</html>
“移动”如何?在我们能够帮助您之前,您需要添加更多信息。 – Josiah
我确定这很清楚这意味着什么,例如,如果我有一个图像在某个位置,并想稍微向上,向下,向左或向右移动它。 – toadflax
Err ...“这是我想要移动的图像!” – Josiah