请帮我生成一个html网页背景颜色为深绿色中间有竖向排列且水平居中的3个按键每个按键点击后跳转到一个新的url
<!DOCTYPE html>
<html>
<head>
<title>My Page</title>
<style>
body {
background-color: darkgreen;
}
.button {
background-color: white;
color: darkgreen;
padding: 10px 20px;
margin: 10px;
border: none;
border-radius: 5px;
font-size: 20px;
cursor: pointer;
}
.button:hover {
background-color: darkgreen;
color: white;
}
.container {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
height: 100vh;
}
</style>
</head>
<body>
<div class="container">
<button class="button" onclick="window.location.href='http://www.google.com'">Google</button>
<button class="button" onclick="window.location.href='http://www.facebook.com'">Facebook</button>
<button class="button" onclick="window.location.href='http://www.twitter.com'">Twitter</button>
</div>
</body>
</html
原文地址: https://www.cveoy.top/t/topic/gqm3 著作权归作者所有。请勿转载和采集!