February 2012
1 post
January 2012
1 post
Fixing OSX Lion DNS Search Domains →
Note to future self.
August 2011
1 post
June 2011
1 post
May 2011
2 posts
In the past decade or so, researchers have produced a significant body of...
– Slate states the obvious about the shittiness of long commutes in only 1000 words.
This is why every dollar (of the many) I spend on my apartment, a ~5 minute bike ride from work, is money well spent. Each day I bypass gridlocked traffic on Coronation Drive while cruising along the riverside...
April 2011
3 posts
One time I was really tired and I started up...
seawitchery:
aidara:
gyzym:
arineat:
cerebrobullet:
queercakes:
16fcali:
It was hilarious.
Then I went to sleep, played some more the next day, and discovered that at some point it had gone from “hilarious” to “wait, what? was I drunk?”
You’re big now
You’ve grown up
so everyone needs to see this
Well, hell, I’ll always reblog a good penis joke. xD
What is...
3 tags
To make ListViews zebrafied
Note to self:
<%#Container.DisplayIndex % 2 == 0 ? "odd" : "even"%>
March 2011
5 posts
Marriage
Stacey: What if I live to be 150 years old?
Me: Well, I won't. I'm sure of that.
Stacey: I know. I'm looking forward to finally having some alone time.
February 2011
1 post
January 2011
1 post
Puella Magi Madoka Magica 04: A Certain Damned... →
So I’ve been writing episodic blog posts and other random banter in my “other blog”, located at blo.cx - here’s the latest.
I’ll keep this feed for my stuff about Work, though (incl Python, JS, whatnot).
December 2010
4 posts
8 tags
November 2010
1 post
October 2010
4 posts
6 tags
Non-Input onChange events
Here’s something useful.
A scenario I stumbled upon, was about firing an event in the similar manner that the onChange event does for web form inputs, but for any other element in the DOM. Some google-fu later I discovered the DOMAttrModified event, which does just that.
Except that it doesn’t work in IE. I thought that it was a bit too easy. IE does its stuff in its own...
The very existence of flame-throwers proves that some time, somewhere, someone...
– George Carlin
September 2010
13 posts
6 tags
IE7 PNG transparency support not native after all
Well this is really fun. Not.
It seems that the PNG transparency support introduced in IE7 isn’t native at all. It’s the same hack as in IE6, but applied automatically under the hood. The hack, or fix, whichever you decide to call it, is the method of using the DXImageTransform filter’s AlphaImageLoader function to introduce PNG transparency to your images, and if you...
Mind blowing photographs of animals inside womb
yourmindblown:
These amazing embryonic animal photographs of dolphins, sharks, dogs, penguins, cats and elephants are from a new National Geographic Documentary called “Extraordinary Animals in the Womb”. The show’s producer, Peter Chinn, used a combination of three-dimensional ultrasound scans, computer graphics and tiny cameras to capture the process from conception to birth. They are the...
5 tags
JavaScript Browser Console dependency, part 2
As a follow up to my previous post on a dummy JavaScript console object, some thoughts on refining it;
if(console === "undefined") {
var console = {
log: function() {}
}
}
Also one additional method could be:
console = console || { log: function() {} }
But, I haven’t yet tested it out properly to see possible brainfarts. Also, don’t forget to include other...
3 tags
IE7 and button paddings
*+html input { overflow: visible; }
This makes IE7 behave with buttons and their over large paddings.
Naturespace - Holographic Audio →
Note to self; this is awesome
The single line to fix all your IE problems (and...
* { zoom: 1; }
Early new year's resolution
Learn to use try…catch in JS. Do it.
4 tags
Not in my nose, and other strangely erotic and...
I present to you, dicks;
var favoriteLink = $(".fav-link");
favoriteLink.click(function () {
var
_url = window.location.href,
_title = document.title;
if (document.all) { // Lol internets explorer
window.external.AddFavorite(_url, _title);
} else if (window.sidebar) { // Lol firefox
window.sidebar.addPanel(_title, _url, '');
}
return...
3 tags
"Damn it, Arthas! As my future king, order me to...
I just fucking LOL. As seen on the official forums, reverse dialogue!
Arthas: I watch my tone with you, old man. I may be the prince, but you’re still my superior as a paladin.
Uther: As if you could forget. Yes Arthas, there’s something about the plague I should know. …Oh no, it’s already begun. These people may look fine now, but it’s only a matter of time...
August 2010
2 posts
2 tags
underscore.js →
Why haven’t I known about this before?
2 tags
Studio Styles →
For all Visual Studio color scheme needs.
July 2010
3 posts
4 tags
Firebug Console dummy object
Something so obvious, I’m ashamed of not thinking about this earlier. When I’ve been relying on using Firebug’s console (as well as WebKit’s), calling on console.log() gives the usual “not a function” error.
At first, my solution was this:
function cout(str) {
if(typeof(console) != "undefined") console.log(str);
}
Well all’s fine and dandy, it...
2 tags
Attempt #1 at JS Namespaces
Trying to see how well I can tie up my brain into a knot;
var Main = Main || {};
(function ()
{
function NS() {
var privateVar = "";
this.publicVar = "";
this.setter = function(str) {
privateVar = str;
}
this.getter = function() {
alert(privateVar);
}
}
Main.NS = new NS();
})();
var o =...
4 tags
Microsoft is great at writing error messages
An error was encountered while opening associated documents the last time this solution was loaded. Document load is being skipped during this solution load in order to avoid that error.
What the fuck is VS2010 trying to say here?
June 2010
2 posts
5 tags
Capt. Obvious of JS
In a series of very obvious reasons, which I had completely forgot about, do not try to pass an object containing the key class, for instance in jQuery, to an element, but instead use "class", as in, with quotes. This’ll save you from WebKit parse errors and feelings of shame.
Captain Obvious signing out.
5 tags
My face when I realized IE doesn't understand...
So, apparently IE wants to be the shitty kid around the block (again) and seems to be bitchy about getting the CSS background-position property values. Because:
$("#navigation").css("background-position"); returns undefined
but:
$("#navigation").css("background-position-x"); returns "0px"
In the light of this, have a small jQuery plug-in, thanks to Dextrose.
March 2010
6 posts
Jesus said unto his disciples: “I will grant you eternal...
I’m gonna train my children to say sudo instead of please
– digicow (from qdb)
2 tags
Rambling about JS
Remember, you can attach actions to events by assigning an anonymous function to said event.
Before this, yes, I know, this is basic, but I’ve a post coming on the subject on my way of learning things. :D
Example: Let’s open up an image from a link, and preload the image before displaying it and using jQuery to display, because I’m lazy with vanilla JS;
var preload-image =...