그래서 나는 청소를 위해 웹 사이트를 만들었지 만 거의 모든 페이지를 올리기 위해 암호를 묻는 프롬프트가 필요합니다. . 내가 Jquery를 사용하고 비밀 번호 promt를 표시하는 유일한 방법은 내가 잘 못된 페이지를 새로 고친 후입니다. 한 페이지를 다른 페이지로 링크하는 방법이 필요하며 페이지를보기 전에 암호 프롬프트를 표시하십시오. 다음은 중요한 html입니다. 또한 할 수 있다면. 페이지를 새로 고침 할 때마다 CSS의 모든 내용이 사라지고 텍스트가 그대로 남습니다. 그걸로 제발 도와 줄 수 있다면.jquery 암호를 묻는 메시지가 필요합니다 (간단해야 함)
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>jQuery</title>
<link rel="stylesheet" href="../themes/scavenger-hunt.min.css" />
<link rel="stylesheet" href="../Publish/jquery-mobile/jquery.mobile.structure-1.0.min.css" />
<script src="http://code.jquery.com/jquery-1.8.3.min.js"></script>
<script src="http://code.jquery.com/mobile/1.3.0-rc.1/jquery.mobile-1.3.0-rc.1.min.js"></script>
<body>
<script language="javascript">
var password
var pass1="123"
password=prompt('Please enter password to view page')
if (password==pass1)
alert('password correct! Press ok to continue.')
else{
window.location="index.html";
alert('password incorrect! Redirecting')
}
</script>
<div data-role="page" id="home">
<div data-role="header">
<h1>Hint 1</h1>
</div>
이 필요 얼마나 안전해야합니까입니까? 내가 당신의 청소부 사냥을하다가 10 초 안에 암호 검증을 무시하고 승리 할 것이기 때문입니다. – mrtsherman
jquery 코드가 없습니다. – Dave
@mrtsherman 그게 안전하지 않아야하고, 그것의 모바일 그래서 우회하는 조금 더 힘들어. – saulpm