Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

Matt Motherway webxl

Block or report user

Report or block webxl

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@webxl
webxl / 2fiddle.js
Created Sep 22, 2011
Load into JSFiddle
View 2fiddle.js
if (typeof gistJSUrl != 'undefined') {
frame = document.createElement('iframe');
body = document.getElementsByTagName('body')[0];
body.appendChild(frame);
frame.src = gistJSUrl;
form = document.createElement('form');
body.appendChild(form);
form.action = "http://jsfiddle.net/api/post/mootools/1.2/";
@webxl
webxl / objExtend.js
Created Sep 22, 2011 — forked from addyosmani/objExtend.js
JavaScript object 'namespace' extension experiments
View objExtend.js
$(function(){
//===========================================================
// JavaScript object 'namespace' extension experiments
// by @addyosmani (comparing deep extension in vanilla JS vs.
// jQuery's $.extend)
//
//
// The goal here is to:
//
@webxl
webxl / grid.js
Created Sep 21, 2011
CSS prototyping bookmarklet
View grid.js
javascript:(function(){s1=document.createTextNode('.guidesOn::before { content:""; position:fixed; background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAYAAAAeP4ixAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAZdEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjVJivzgAAAAyUlEQVRoQ%2B2abQqAIBBEPW1X6CzdqTv1RUFIipi2o72gPyXV7uybKci5wDZM8xI6dz%2Buvs6pP2Dq81GI2qiiiJkiOzQ97EGHTXUF9XUwYsaI2o1LjyqjpaYwiqDI2YFs2HtI9Wjx2Z0R%2B1ADdmB%2FC7taB0uzCSNqCqOImSIkeyW7xLXMZvqjdzJcS01hFEGRSnbe3miR7JVGgWRXcxkUQRFgj%2F8Y8htGtkJHL%2FvGaGtKd6bU9Z4C%2FCiEZDeCPahIa%2FbbDSNX433mVkIrV5rTnhDyAAAAAElFTkSuQmCC) 50% 0; z-index:1; top:0; right:0; bottom:0; left:0; opacity:.3; pointer-events:none; } * { -webkit-user-modify: read-write; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; } a { -webkit-user-modify: initial; }');s2=document.createTextNode('#a1_z { background-color: #fff; background-color: rgba(255,255,255,.8); float: left; position: fixed; z-index:2; padding: 3px; bo
View logResult.js
function logResult(result) {
var container = document.createElement('PRE');
document.body.appendChild(document.createElement('HR'));
document.body.appendChild(container);
container.setAttribute('class', 'logResult');
container.innerHTML = typeof result + ': ' + result;
}
/*
logResult(234);
@webxl
webxl / Module.js
Created Aug 24, 2011
new & this vs. module pattern
View Module.js
// ht: http://www.digital-web.com/articles/scope_in_javascript/
function BigComputer(answer) {
var the_answer = answer;
var ask_question = function () {
return check_answer(the_answer);
}
function check_answer(ans) {
return the_answer;
}
@webxl
webxl / flot_v_raphael.html
Created Oct 19, 2010 — forked from andrewwatts/flot_v_raphael.html
Correcting for additional default charting options in flot
View flot_v_raphael.html
<!DOCTYPE HTML>
<html>
<head>
<title>flot vs raphael</title>
<script type="text/javascript" src="jquery.min.js"></script>
<script type="text/javascript" src="jquery.flot.min.js"></script>
<script type="text/javascript" src="raphael.js"></script>
<script type="text/javascript" src="g.raphael-min.js"></script>
You can’t perform that action at this time.