The internet is one of the largest nets in the entire world. Here are some things that I like/find humorous/want others to see/what-have-you.

MyWednesdayFix: A Website For Comic Book Junkies

Feb
11
Posted on February 11, 2014 at 11:27 pm

For the past several months, I’ve been working on building MyWednesdayFix.com, and it’s damn near close to being at v1.0.

I decided to build this site primarily to solve a simple problem — to provide a place to find an answer to the question “what new comic books came out this week?” Every Wednesday morning, the site is automatically updated with a list of the comics available in stores for the week. If nothing else I built this site for myself, so that each Wednesday, while I’m riding the train into DC, I can browse the new releases and get an idea of what I want to buy when I head to Big Planet after work.
 
mywednesdayfix-320
(more…)

Server-Sent Events: They’s Niiice

May
24
Posted on May 24, 2012 at 5:50 pm

I first heard about Server-Sent Events a few months ago, though I didn’t have a chance to take ’em out for a test drive until this past week. I have to say, I’m impressed.

Server-Sent Events refers to a new-ish spec which allows a server to push data to the web browser, requiring only a few lines of native JavaScript on the client-side. This new interface drastically simplifies web applications which rely on periodic updates from a server-side application. For example, Mozilla provided this example of a “wall” built using Server-Sent Events. I wrote some sample code of my own to see just how hard it is to implement Server-Sent Events, and the answer is, it’s not.

(more…)

“Super Bass” in JavaScript

Apr
07
Posted on April 7, 2012 at 3:39 pm

Inspired by Jack Shepherd’s literal songs.

var theBoys=document.getElementsByTagName('boy'),
deck=[];
function lookForDude(){
   var dude;
   for(i=0;i<theBoys.length;i++){
      if(theBoys[i].system==='boomin\''&&theBoys[i].top==='down'
      &&theBoys[i].AC.coolinSystem){
         var theClub=document.getElementById('club');
         theClub.appendChild(theBoys[i]);
         theBoys[i].blazin++;
         deck.push(theBoys[i].getElementsByTagName('stack'));
         theBoys[i].ill==theBoys[i].real==true;
         theBoys[i].deal==Math.floor(Math.random()*2)==1?true:false;
         while(document.getElementsByTagName('bottle').length){
            document.getElementsByTagName('bottle').pop();
         }
         theBoys[i].getElementsByTagName('build')[0].style.textAlign='right';
         theBoys[i].temperature--;
         theBoys[i].dope=true;
         if(Math.floor(Math.random()*2)==1){
            for(j=0;j<theClub.getElementsByTagName('boy');j++){
               if(theClub.getElementsByTagName('boy')[j].coke.length===0)
                  theClub.getElementsByTagName('boy')[j].coke++;
            }
         }
         document.getElementById('plane').getElementsByTagName('class')[0]
         .appendChild(theBoys[i]);
         var trip=function(boy){
            if(boy.trip)
               return 'mutha fuckin\' trip';
         };
         var isTrip=trip(theBoys[i]);
         var ship={
            ship:{
               sailor:theBoys[i]
            }
         };
         var drip=function(){
            theBoys[i].getElementsByTagName('lip')[0].getElementsByTagName('lip')[0]
            .innerHTML='kiss';
         };
         if(theBoys[i].addEventListener)
            theBoys[i].addEventListener('drip',drip,false);
         else if(theBoys[i].attachEvent)
            theBoys[i].attachEvent('ondrip',drip);
         dude=theBoys[i];
      }
   }
   return dude;
}
console.log(lookForDude());
function slapHo(){
   var ho;
   if(window.XMLHttpRequest){
      ho=new XMLHttpRequest();
   else if(window.ActiveXObject)
      ho=new ActiveXObject('Microsoft.XMLHTTP');
   ho.open('GET','/ho-json');
   ho.send();
   ho.onreadystatechange=function(){
      if(ho.readyState==4){
         if(ho.responseText.lookin)
            return;
      }
   }
}
var willHoGetSlapped=slapHo();
alert('Excuse me, you\'re a hell of a guy.\n'+
'I mean my, my, my you\'re like pelican fly.\n'+
'I mean, you\'re so shy and I\'m lovin\' your tie.\n'+
'You\'re like slicker than the guy with the thing on his eye, oh!');
function didShe(){
   return;
}
function whoTheEffSheIs(){
   if(didShe())
      alert('She is Nicki Minaj, she macks them dudes up.\n'+
      'Back coupes up, and chuck the deuce up.');
}
whoTheEffSheIs();
var boy=lookForDude(),
superBass='boom, badoom, boom, boom, badoom, boom bass';
function runAway(){ 
   var heartbeat=document.getElementById('heartbeat');
   heartbeat.style.position='absolute';
   while(Number(heartbeat.style.left.replace('px',''))<window.innerWidth){
       heartbeat.style.left=(Number(heartbeat.style.left.replace('px',''))+1)+'px';
   }
   heartbeat.getElementsByTagName('beating')[0].innerHTML='/images/drum.png';
   boy.parentNode.insertBefore(heartbeat,boy);
   return boy.getElementsByTagName('feeling')[0].indexOf(superBass);
}
var canBoyFeelIt=runAway();
function setBoysBass(){
   boy.bass=superBass;
}
setBoysBass();
function checkBoysBass(){
   if(boy.bass===superBass)
      return;
}
var isThatThatSuperBass=checkBoysBass();
setBoysBass();
isThatThatSuperBass=checkBoysBass();
for(i=0;i<theBoys.length;i++){
   if(theBoys[i].getElementsByTagName('polo').length&&
   (theBoys[i].entrepreneurial||theBoys[i].mogul)){
      var crew=theBoys[i].parentNode.childNodes;
      for(j=0;j<crew.length;j++){
         if(crew[j]!==theBoys[i])
            theBoys[i].parentNode.removeChild(crew[j]);
      }
      var cap=document.createElement('cap');
      cap.style.width='100%';
      theBoys[i].appendChild(cap);
      document.getElementById('mac').disabled='disabled';
      var thatLook=document.createElement('look');
      document.getElementById('her').appendChild(thatLook);
      document.getElementById('her').removeChild(document.getElementById('her')
      .getElementsByTagName('panties')[0]);
      var excuseHer=document.createElement('p');
      excuseHer.innerHTML='You\'re a hell of a guy.<br />'+
      'You know I really got a thing for American guys.<br />'+
      'I mean, sigh, sickenin\' eyes.<br />'+
      'I can tell that you\'re in touch with your feminine side, oh!';
      theBoys[i].appendChild(excuseHer);
   }
}
whoTheEffSheIs();
canBoyFeelIt=runAway();
setBoysBass();
isThatThatSuperBass=checkBoysBass();
setBoysBass();
isThatThatSuperBass=checkBoysBass();
document.getElementById('her').getElementsByTagName('life')[0].appendChild(boy);
boy.style.position='fixed';
boy.style.top='0';
boy.style.left='0';
canBoyFeelIt=runAway();
setBoysBass();
isThatThatSuperBass=checkBoysBass();
setBoysBass();
isThatThatSuperBass=checkBoysBass();

CORS: Worth Geeking Out Over

Feb
05
Posted on February 5, 2012 at 5:36 pm

As was recently and nerdily mentioned on Connection Café, I’ve been working with the world-class engineering team at Convio to implement support for Cross-Origin Resource Sharing (CORS) in the new release of our API. Despite having been around since Firefox 3.5 (and, like, Chrome 2.0), CORS has received little attention from the web development community at large. In my opinion, it is the most revolutionary and exciting change to the Internet in a long while, and deserves much more fanfare than things like, say, box-shadow.

(more…)

4 PETA Campaign Posters I Wish Were Real

Jan
11
Posted on January 11, 2012 at 2:51 am

You know what I miss most about working for PETA (besides hanging out with A-list celebrities like Benji Madden)? We had this tradition when we launched a new campaign where we’d get all of the staff, interns, and volunteers together in a meeting room to kick around creative ideas, from how to market the campaign online to what sorts of props we should use at demonstrations. My favorite part of these brainstorming seshes was coming up with campaign taglines. For whatever reason, some of my most brilliant ideas never actually made it to print. Here are some campaign posters that I wish so hard were real.

1) Premarin

If you’re not a middle-aged woman, you probably have no fucking clue what a “Premarin” is. Premarin is a drug used to treat the symptoms of menopause. As if menopause wasn’t already gross enough, Premarin is made by strapping rubber bags to forcibly impregnated horses and collecting their urine. I swear to God I’m not making this shit up — the name Premarin is in fact an acronym for PREgnant MARes’ urINe. To produce this hot flash piss cocktail, Pfizer keeps horses pregnant for about 12 years straight in stalls so tiny they can’t even turn around, and deprives them of water in order to squeeze more estrogen out of them.
 

This is Premarin, Don't Let Anyone Tell You Different - PETA poster
 

(more…)

What the fuck is a ‘Forbe’?

Nov
11
Posted on November 11, 2011 at 1:38 am

Google Analytics just helped me discover that there’s a post on Forbes.com which mentions both whatthefuckisasloth.com and whatthefuckcanidoforseals.com. In an interview with Zach Golden, the mastermind behind whatthefuckshouldimakefordinner.com, Forbes contributor Jesse Thomas writes that What the Fuck Should I Make for Dinner inspired …

“several knock-offs, like What the F*@# Can I Do for Seals? and What the F*@# is a Sloth?”

This is amazing for two reasons:

1) Dudebro got away with saying fuck like 50 times on a website that’s usually a bunch of stuffy financial news.
2) Of all of the possible websites to have cited as examples, he chose two built by me.

Forbes joins countless other highly-reputable news sites who have name-dropped whatthefuckisasloth, including BuzzFeed, The L Magazine and yes, even GQ.

Now if only I could convince the even stuffier folks that monitor Wikipedia to stop reverting my edits.

What the fuck is a sloth?

Aug
25
Posted on August 25, 2010 at 5:23 pm

Today I got bored and I made this.

It all started when I told my wife, Sarah, that she was a sloth (for no particular reason that I can remember), and we both realized that we had no idea what the fuck a sloth was. So, I figured I’d help other people who were in a similar situation, and thus whatthefuckisasloth.com was born.

Embedding YouTube Videos on Secure Web Sites

May
22
Posted on May 22, 2009 at 11:13 pm

Currently YouTube doesn’t offer an option of embedding its videos via HTTPS, so if you try to add a video to a secure page browsers will display a security warning. If you use swfobject.js instead of the code provided by YouTube (as you should!), you’ll find the security warning goes away … in some browsers; IE is fooled and doesn’t display a warning, while FireFox will still show its little red exclamation mark in the status bar indicating that not all elements on the page are secure:

The same issue occurs in Opera, as well as Flock and other Mozilla browsers.

And obviously, since swfobject is a JavaScript file, if JavaScript is disabled in the browser the only option for showing the video is a plain ol’ Flash object inside noscript tags, and in that case the security warning is displayed for all browsers.

The workaround I came up with is to upload a SWF to the secure site that acts as a proxy and loads the YouTube video (since Flash has its own security model, it doesn’t matter that the video is not served via HTTPS).

(more…)

Put TwitStream on Your Site!

People Who Are Not Me