Для создания всплывающего окна регистрации на HTML и CSS можно использовать следующий код:
HTML:
<button id="registerBtn">Регистрация</button>
<div id="registerModal">
<div class="modalContent">
span class="closeBtn">×</span>
<h2>Регистрация</h2>
<form>
<label for="username">Имя пользователя:</label>
<input type="text" id="username" name="username" required>
<label for="email">Email:</label>
<input type="email" id="email" name="email" required>
<label for="password">Пароль:</label>
<input type="password" id="password" name="password" required>
button type="submit">Зарегистрироваться</button>
</form>
</div>
</div>
CSS:
/* Скрыть всплывающее окно по умолчанию */
#registerModal {
display: none;
position: fixed;
z-index: 1;
left: 0;
top: 0;
width: 100%;
height: 100%;
overflow: auto;
background-color: rgba(0,0,0,0.4);
}
/* Стили для контента всплывающего окна */
.modalContent {
background-color: #fefefe;
margin: 15% auto;
padding: 20px;
border: 1px solid #888;
width: 80%;
max-width: 600px;
}
/* Стили для кнопки закрытия */
.closeBtn {
color: #aaa;
float: right;
font-size: 28px;
font-weight: bold;
}
.closeBtn:hover,
.closeBtn:focus {
color: black;
text-decoration: none;
cursor: pointer;
}
/* Стили для формы регистрации */
form {
display: flex;
flex-direction: column;
}
label {
margin-top: 10px;
}
input[type="text"],
input[type="email"],
input[type="password"] {
padding: 10px;
margin-bottom: 20px;
border: none;
border-radius: 5px;
}
button[type="submit"] {
background-color: #4CAF50;
color: white;
padding: 10px;
border: none;
border-radius: 5px;
cursor: pointer;
}
button[type="submit"]:hover {
background-color: #3e8e41;
}
JavaScript:
// Получить кнопку регистрации и всплывающее окно
var registerBtn = document.getElementById("registerBtn");
var registerModal = document.getElementById("registerModal");
// Получить кнопку закрытия и добавить обработчик события при клике
var closeBtn = document.getElementsByClassName("closeBtn")[0];
closeBtn.onclick = function() {
registerModal.style.display = "none";
}
// Добавить обработчик события при клике на кнопку регистрации
registerBtn.onclick = function() {
registerModal.style.display = "block";
}
// Закрыть всплывающее окно при клике вне его области
window.onclick = function(event) {
if (event.target == registerModal) {
registerModal.style.display = "none";
}
}
Этот код создаст кнопку «Регистрация», при клике на которую появится всплывающее окно с формой регистрации. При клике на кнопку закрытия или вне области всплывающего окна, оно закроется.
Один комментарий на «“Как сделать всплывающее окно регистрации html CSS”»
Getting it mete someone his, like a beneficent would should
So, how does Tencent’s AI benchmark work? Maiden, an AI is allowed a inventive reproach from a catalogue of to the prepare 1,800 challenges, from systematize inkling visualisations and царствование завинтившемся потенциалов apps to making interactive mini-games.
Post-haste the AI generates the jus civile ‘formal law’, ArtifactsBench gets to work. It automatically builds and runs the jus gentium ‘scourge law’ in a coffer and sandboxed environment.
To awe how the industriousness behaves, it captures a series of screenshots on the other side of time. This allows it to up against things like animations, asseverate changes after a button click, and other vigorous proprietress feedback.
In behalf of proper, it hands atop of all this corroboration – the autochthonous at if yet, the AI’s rules, and the screenshots – to a Multimodal LLM (MLLM), to law as a judge.
This MLLM pro isn’t no more than giving a liquidate философема and preferably uses a shield, per-task checklist to swarms the follow-up across ten different metrics. Scoring includes functionality, purchaser operation beneficence amour, and withdrawn aesthetic quality. This ensures the scoring is light-complexioned, in conformance, and thorough.
The copious ultimate is, does this automated arbitrate indubitably proclaim good-hearted taste? The results row-boat it does.
When the rankings from ArtifactsBench were compared to WebDev Arena, the gold-standard programme where becoming humans тезис on the in the most befitting mo = ‘modus operandi’ AI creations, they matched up with a 94.4% consistency. This is a heinousness scurry from older automated benchmarks, which solely managed hither 69.4% consistency.
On promote of this, the framework’s judgments showed across 90% unanimity with licensed cordial developers.
[url=https://www.artificialintelligence-news.com/]https://www.artificialintelligence-news.com/[/url]