After successfully creating a password redirect page where entering the correct password redirects you to another URL (psswrdtest.tumblr.com with the password as correctpsswrd, redirecting to google.com*), I attempted to improve it by making the password page fade in to reveal the blog if the correct password is entered. Despite inserting my password code into the theme and using jQuery, it still doesn't work! Here is my latest attempt.
Here is the CSS:
#hamuko {
position:fixed;
display:table;
width:100%;
height:100%;
background:{color:background}
url('{image:background}') left bottom repeat;
{block:iflittlecursor} cursor: url(http://i.imgur.com/ZOrzC.png), auto; {/block:iflittlecursor}
z-index:2147483647;
top:0;
}
#hamuko #aki {
display:table-cell;
font-size:16px;
vertical-align:middle;
text-align:center;
{block:iflittlecursor}cursor: url(http://i.imgur.com/ZOrzC.png), auto; {/block:iflittlecursor}
}
#hamuko #sooj {
...
This is my jQuery code:
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.min.js"></script>
<SCRIPT LANGUAGE="JavaScript">
function goForit() {
var passwd;
passwd = document.getElementById('yosugay').value;
if(passwd=="{text:password}"){
$(document).ready(function() {
$('#hamuko').fadeOut(1000);
});
else{
alert('{text:wrong alert}');
}
}
</SCRIPT>
And here is the HTML added:
<body>
<div id="hamuko">
<div id="sooj">
<img src="{image:pixel}" />
{text:form text}
<img src="{image:pixel}" />
</div>
...
However, the results are not as expected. The issues include:
- The password code is not showing up
- The transition from psswrdtest.tumblr.com to yamagitenshi.tumblr.com went wrong, resulting in a useless white box on the page
- To view the full failed attempt code, check the source of http://yamagitenshi.tumblr.com
If anyone could provide insights into what might be going wrong, I would greatly appreciate it. Even if you can't, thank you for taking the time to read this.