richard-m.blogspot.com
Too much recursion: DOM Node Creation Helper Function-updated
http://richard-m.blogspot.com/2006/08/dom-node-creation-helper-function.html
Friday, August 04, 2006. DOM Node Creation Helper Function-updated. Added functionality for text node creation: Just pass in node type as 'textnode' and then the second argument is your text, defaults to. Now you can use it to add styles or attributes to an existing node. Just pass in the node (instead of a type of node). Generic Create Element, $X, exNihilo() R.E.M. 2006. Creates element and/or adds attributes to node and/or adds styles to node. Var exNihilo = $X =function (el,attributes,styles) {.
richard-m.blogspot.com
Too much recursion: Quick and Dirty Multiple Inheritence in Javascript
http://richard-m.blogspot.com/2006/07/quick-and-dirty-multiple-inheritence.html
Friday, July 14, 2006. Quick and Dirty Multiple Inheritence in Javascript. This has no checks for overriding properties so last object(arguement) wins:. Function newObject() richard maloney 2006. Usage:send in n objects and it'll return one object inheriting. All the prop and methods of the objects passed in */. Var o=arguments,len=o.length-1,nextObj;. Fprototype =o[0], nextO=o[len 1];. For ( var i in nextO) { f.prototype[i]=nextO[i]; }. Return new f();. Here is some testing code:. Submit to digg.com.
richard-m.blogspot.com
Too much recursion: Function.prototype.toEvent (bindAsEventListener)
http://richard-m.blogspot.com/2006/09/functionprototypetoevent.html
Saturday, September 23, 2006. Function.prototype.toEvent (bindAsEventListener). This one keeps this and sends event object as the first argument (no more checking! It also has only one parameter or parameters maybe- the argument/s you want to send to your function. Thats it! Bonus: the last argument is the co-ordinates of the event. Say you want to attach an onclick event to a button with id of 'myBut':. Function doSomTing(e,h,w){. Alert(this.nodeName " " h w);. Return function( ev ){ r[0]= ev= ev event;.
richard-m.blogspot.com
Too much recursion: String.prototype.exe part2
http://richard-m.blogspot.com/2006/09/stringprototypeexe-part2.html
Friday, September 22, 2006. String.prototype.exe part2. Think I got it this time:. Executes string as body of function, args = comma seprated arguments. Ex: 'var h=arguments[0]; var w=arguments[1]; alert(h " n" w)'.exe('Hello','World');. String.prototype.exe = function(){. Eval( 'function(){' this '}' ).apply(this,arguments);. Posted by richard.m Perma Link. Bookmark in del.icio.us. Submit to digg.com. Submit to slashdot.com. Comments: Post a Comment. Links to this post:.
richard-m.blogspot.com
Too much recursion: Easy Class setTimeout call keeping 'this'
http://richard-m.blogspot.com/2006/08/easy-class-settimeout-call-keeping.html
Sunday, August 20, 2006. Easy Class setTimeout call keeping 'this'. I'm working on an a.p.i called this.js. Its a jquery clone in its functionality. I needed to call functions within the same class, keeping this all the same. (arguments can be passed using the same technique, but it borks in IE6.its better to have the arguments as class members anyway). Here is some code from this.js showing the technique:. ThisfadeIn= function ( speed, delay ){. Thisel.style.visibility='visible';. Submit to digg.com.
richard-m.blogspot.com
Too much recursion: Say Your Prayers with Javascript
http://richard-m.blogspot.com/2006/07/say-your-prayers-with-javascript.html
Sunday, July 23, 2006. Say Your Prayers with Javascript. Boy I love Javascript. Now its even saying my prayers for me. :). Heres an app I coded, called Rosary.Beads.v1.0. It says the rosary (a Catholic prayer said on beads) automatically. It features low tech cross-domain 'ajax' counter, 2 images, flash audio, and slightly overcomplicated js. ;). Posted by richard.m Perma Link. Bookmark in del.icio.us. Submit to digg.com. Submit to slashdot.com. Comments: Post a Comment. Links to this post:.
richard-m.blogspot.com
Too much recursion: Almost ajax- Synchronous Javascript Remote Scripting
http://richard-m.blogspot.com/2006/07/almost-ajax-synchronous-javascript.html
Thursday, July 13, 2006. Almost ajax- Synchronous Javascript Remote Scripting. Ok, its time I started to do some. Asynchronous JavaScript and XML. Type stuff. Why? Maybe it'll help get me a job. There are already so many libraries and good stuff out there, I'm not going to re-invent the wheel. In the next few weeks I'll look at some good/and/or/popular ajax 'suites'. I got my eye on a few obscure ones; I'll share these after I know what a bit more. Var done is to keep track of setTimeout checks. Im impre...
richard-m.blogspot.com
Too much recursion: Confirm User Exit
http://richard-m.blogspot.com/2006/07/confirm-user-exit.html
Sunday, July 23, 2006. Here is some code that alerts users that leaving the page might be a bad idea. It counts the number of attempts to leave the page and stops displaying the message after n attempts. Times ; if(times= 2){window.onbeforeunload=' }. Return 'All your sensitive information (email,posts,Google searches) '. Is gathered by smart routers and warehoused in your namespace';. Window.onbeforeunload= confirmExit;. Posted by richard.m Perma Link. Bookmark in del.icio.us. Submit to digg.com.
typeit.org
About TypeIt
http://www.typeit.org/about.htm
TypeIt app for Windows. If you have the need to type anything in a foreign language which has accents and other strange-looking characters, and you only have a US keyboard, your life used to be miserable. You used to have to do one of the following:. Ignore the special characters. Memorize unintuitive keyboard shortcuts such as Alt 0128. Go letter-hunting with the Character Map in Windows or Word. Buy and install third-party text input software. Ctrl letter. By Chris Veness. When developing the cu...
richard-m.blogspot.com
Too much recursion: Higher Order DOM Scripting
http://richard-m.blogspot.com/2006/07/higher-order-dom-scripting.html
Thursday, July 27, 2006. Higher Order DOM Scripting. Here is an example of using functional programming to speed up DOM scripting. We'll take a Quirksmode text select script, (beautiful in its own right), and give it the functional treatment. After the first function call(in this case), or after initialization, what this type of programming gives us is a function that no longer needs any environment object checks. This is as fast as browser programming can get. Else if (document.getSelection){.