Hacker News new | past | comments | ask | show | jobs | submit login

Here you go. Copy paste into your url bar. Only tested in Chrome (edit: apparently also works in safari 5)

javascript:var dashes = ""; var num = 20; while(--num) dashes += "-"; setInterval(function() { window.history.pushState("", "", dashes.slice(0, num % 20) + "foo" + dashes.slice(num % 20)); num++;}, 500)




If you change the window.history.pushState() call to window.history.replaceState(), it doesn't add bazillions of entries to your history, which makes it slightly more practical.

javascript:var dashes = ""; var num = 20; while(--num) dashes += "-"; setInterval(function() { window.history.replaceState("", "", dashes.slice(0, num % 20) + "foo" + dashes.slice(num % 20)); num++;}, 500)


Ok, here's a first pass... http://jsfiddle.net/cowboy/FB9Nd/show/


That is simultaneously one of the cooler, and more horrifying things I have seen.

With Great Power, comes great potential for horrible, horrible abuse.


Absolutely. I was thinking this could be "abused" in the same way that animated status bars were in the 90s.

Of course, I had to try it out...

javascript:var s=[119,101,108,99,111,109,101,45,116,111,45,104,97,99,107,101,114,45,110,101,119,115];var c=1;var mod=s.length+1;setInterval(function(){window.history.replaceState("","", setString())}, 200);function setString(){var n="";if(!(c % mod)){c=1}else{c++}for(i=0;i<s.length;i++){n+=String.fromCharCode(s[i]-(s[i]==45||i!=c-1?0:32))}return n+".aspx!!!"};


Damn, that is annoying! It totally screws up the back button functionality in Safari:

http://imgur.com/41rrV.png


That's sort of the point, isn't it? As it's continuously changing the URL ... I could see this used to make it difficult or impossible for people to leave sites, except by closing the window.


Haha, indeed! (Don't click this if you care about your history) http://kurtly.tumblr.com/sticky-history


And also in Chrome.


Also works in Safari 5, at least.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: