mirror of
https://github.com/smogon/pokemon-showdown-client.git
synced 2026-08-23 19:41:47 -05:00
29 lines
919 B
HTML
29 lines
919 B
HTML
<!DOCTYPE html>
|
|
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
|
<title>Get Assertion</title>
|
|
<link rel="shortcut icon" href="//play.pokemonshowdown.com/favicon.ico" />
|
|
<script src="//play.pokemonshowdown.com/js/lib/jquery-2.1.0.min.js"></script>
|
|
<script src="//play.pokemonshowdown.com/js/lib/jquery-cookie.js"></script>
|
|
Connecting to login server...
|
|
<script>
|
|
$.ajax({
|
|
url: 'http://play.pokemonshowdown.com/action.php?act=getassertion&challengekeyid=2',
|
|
type: 'GET',
|
|
xhrFields: {
|
|
withCredentials: true
|
|
},
|
|
crossDomain: true
|
|
}).done(function(data) {
|
|
var date = new Date();
|
|
date.setTime(+date + 15 * 60 * 1000)
|
|
$.cookie('assertion', data, {expires: date});
|
|
if (location.search) {
|
|
var uri = decodeURIComponent(location.search.substr(1)) + location.hash;
|
|
if (uri.charAt(0) !== '/') uri = '/';
|
|
document.location.replace(uri);
|
|
} else {
|
|
document.location.replace('/');
|
|
}
|
|
});
|
|
</script>
|