Skip to content

Instantly share code, notes, and snippets.

View RedWolves's full-sized avatar

Ralph Whitbeck RedWolves

  • Atlassian
  • Rochester, NY
View GitHub Profile
@RedWolves
RedWolves / about.md
Created August 9, 2011 14:23 — forked from jasonrudolph/about.md
Programming Achievements: How to Level Up as a Developer
/*
* jqModal - Minimalist Modaling with jQuery
* http://dev.iceburg.net/jquery/jqModal/
* Copyright (c) 2007 Brice Burgess <[email protected]>, http://www.iceburg.net
* Licensed under the MIT License:
* http://www.opensource.org/licenses/mit-license.php
*
* $Version: 2007.08.17 +r11
*
*/
@RedWolves
RedWolves / jquery-version.js
Created May 1, 2011 02:43
Sample JSON file I am using for Cross domain JSONP testing
jsfunction({
"jquery": {
"website": "http://jquery.com",
"versions": [
{ "version": "1.5", "releaseDate": "January 1, 2011" },
{ "version": "1.5.1", "releaseDate": "February 1, 2011" },
{ "version": "1.5.2", "releaseDate": "March 1, 2011" },
{ "version": "1.6", "releaseDate": "April 1, 2011" }
]
}
var link = {
href: "",
_url: function() {
var key = "/download.axd/";
return this.href.substr(key.length);
},
extension: function() {
return this._url().substr(33, 3);
},
filename: function() {
//dynamically generated by ASP.NET for the language passed in.
var labels = {
language: 'English',
objectOverlay: {
closeX: 'Close X',
fallback: 'Video for {vid}'
},
global: {
label1: 'label1',
label2: 'label2'
//dynamically generated by ASP.NET for the language passed in.
var globalLabel = {
language: 'English',
labels: {
objectOverlay: {
closeLabel: 'Close X',
fallbackLabel: 'Video for {vid}'
}
}
};
// Did you mean return false?
// 'return false' stops the default behavior of the event
// and prevents it from bubbling up DOM, which kills
// event delegation and may not be what you indented.
// Learn how these event methods can fine tune your
// event handler functions.
$("#clickme").click(function(e) {
//Prevent the default click action from firing.
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>TalkAbstracts</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
<script src="http://github.com/nje/jquery-tmpl/raw/master/jquery.tmpl.js"></script>
<script type="text/javascript">
$(function() {
$.ajax({
function rgbToHex(rgb) {
if (rgb.match(/^#[0-9A-Fa-f]{6}$/)) {
return rgb;
}
var rgbvals = /rgb\((.+),(.+),(.+)\)/i.exec(rgb);
if (!rgbvals) {
return rgb;
}
var rval = parseInt(rgbvals[1]);
var gval = parseInt(rgbvals[2]);
@RedWolves
RedWolves / jquery.fx.speed.SlowAsFatCat.js
Created June 3, 2010 01:18
Plugin that adds a new speed option. At the speed of John Resig's Fat Cat.
$.fx.speeds.SlowAsFatCat = 10000;