Created
July 11, 2011 15:52
-
-
Save twinge/1076156 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="info"> | |
<center><h4><%= @keyword.post_survey_message.present? ? @keyword.post_survey_message : t('contacts.thanks.message') %></h4></center> | |
<br><br> | |
<script type="text/javascript"> | |
var start=new Date(); | |
start=Date.parse(start)/1000; | |
var counts=20; | |
var gonow = false; | |
function CountDown(){ | |
$('#done').click(function() { | |
gonow=true; | |
}); | |
var now=new Date(); | |
now=Date.parse(now)/1000; | |
var x=parseInt(counts-(now-start),10); | |
$('#numOfSecond').html(x); | |
if(!gonow) { | |
if(x>0){ | |
timerID=setTimeout("CountDown()", 100) | |
}else{ | |
window.location="<%= facebook_logout_url %>?next=<%= request.referrer %>"; | |
} | |
} else { | |
window.location="<%= facebook_logout_url %>?next=<%= request.referrer %>"; | |
} | |
} | |
CountDown(); | |
</script> | |
<div id="countdown"> | |
<center> | |
<h4><%= t('contacts.thanks.facebook')%></h4> | |
<br><br> | |
<h3><span id="done"><font color="#0379AE"><%= t('contacts.thanks.done')%></font></span></h3> | |
</center> | |
</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment