Created
December 19, 2016 13:39
-
-
Save shxl/0043ff6d2d48572a5e1152658c1c4ab4 to your computer and use it in GitHub Desktop.
replace images with turnip
This file contains 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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>turn up for what</title> | |
</head> | |
<body> | |
<a href='javascript: function Turnip(a,b){this.ratio=a,this.imageurl=b}function Randomize(a){return Math.floor(Math.random()*a.length)}function imageRatio(a){var b=a.height/a.width;return b>1?"vertical":1===b?"square":1>b?"horizontal":void 0}var getTurnip={init:function(a){this.myTurnip=a},horizontal:function(){return this.myTurnip.filter(function(a){return"horizontal"===a.ratio})},square:function(){return this.myTurnip.filter(function(a){return"square"===a.ratio})}},myTurnip=[new Turnip("horizontal","http://www.lovefoodhatewaste.com/sites/files/lfhw/image/turnip_swede.jpg"),new Turnip("horizontal","http://www.carpediemmag.co.uk/magazine/images/stories/carpediemimages-october2010/turnip.jpg"),new Turnip("horizontal","http://www.harvesttotable.com/wp-content/uploads/2009/06/Turnips-in-garden1.jpg"),new Turnip("horizontal","http://s.hswstatic.com/gif/turnip-image-250x150.jpg"),new Turnip("horizontal","https://www.rhs.org.uk/getmedia/da864b43-6ea5-46de-929e-e0c70f675905/Turnip-Tiny-Pal3x2.jpg"),new Turnip("horizontal","http://c8.alamy.com/comp/CW1WAP/turnip-cut-in-half-CW1WAP.jpg"),new Turnip("horizontal","http://healtheatingfood.com/wp-content/uploads/2015/10/turnips-vegetable.jpg"),new Turnip("horizontal","https://www.quickcrop.co.uk/site/uploads/sys_products/turnip-milan-purple-top.jpg"),new Turnip("horizontal","http://alkhalife.info/sites/default/files/turnips.png"),new Turnip("horizontal","http://i.amz.mshcdn.com/IUrkl1x6ILawwwrMxbzFXXNn-yw=/1200x627/2014%2F10%2F15%2F6d%2Fmichelleoba.b8c70.jpg"),new Turnip("horizontal","http://www.maangchi.com/wp-content/uploads/2012/03/turnips1.jpg"),new Turnip("horizontal","http://cdn.cdkitchen.com/images/cats/687/cat-687-720-1.jpg"),new Turnip("horizontal","http://adambalic.typepad.com/.a/6a00d83451be7269e201538e90da7b970b-800wi"),new Turnip("horizontal","https://www.adaptiveseeds.com/wp-content/uploads/2014/12/p-7841-turnip_aprovecho1.jpg"),new Turnip("horizontal","http://3.bp.blogspot.com/-mEZbNPlCkow/USXx98KhfcI/AAAAAAAAAVs/2Qlbjv4oD_0/s1600/ID-10031872.jpg"),new Turnip("horizontal","http://wpmedia.vancouversun.com/2011/11/turnip-blog.jpg?quality=55&strip=all&w=620&h=460&crop=1"),new Turnip("square","https://charlieeats.files.wordpress.com/2013/10/turnip-for-soup.jpg"),new Turnip("square","http://vignette3.wikia.nocookie.net/farmville2/images/b/b7/Turnip.png/revision/latest?cb=20140824211702"),new Turnip("square","https://pbs.twimg.com/profile_images/1260196236/HugeTurnip_400x400.jpg"),new Turnip("square","http://thinkeatbehealthy.com/wp-content/uploads/2013/07/mg7368-purple-top-turnips-square-web.jpg"),new Turnip("square","http://cdn1.bostonmagazine.com/wp-content/uploads/2014/02/turnips-square.jpg"),new Turnip("square","http://www.deliaonline.com/sites/default/files/styles/square/public/quick_media/ingredient-vegetarian-turnips.jpg?itok=mqcQM0Gg&c=d0050d010c28727cbff260cc75ad1954")];!function(a){getTurnip.init(myTurnip);for(var b=a.getElementsByTagName("img"),c=b.length,d=0;c>d;d++){var e=imageRatio(b[d]),f=Randomize(getTurnip[e]()),g=getTurnip[e]()[f];b[d].src=g.imageurl}}(document);'>turn up for what</a> | |
<p>drag that link into your bookmark bar, hit anytime you see a trump</p> | |
<p>by <a href="https://twitter.com/_sh4d"></a></p> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment