Jaimz, sounds to me more like
$T('hello world') == document.createTextNode('hello world');

On 5/5/06, Jaimz <[EMAIL PROTECTED]> wrote:
yeah i don't follow how usefull the $T() would be. i mean your example is..

(example) var x = $T('hello world');

isn't it just as simple to do this..

var x = 'hello world';

-jaimz


Faison, Sandford (Exchange) wrote:
> Hey all,
>
> I've had these functions for some time now, and would like to offer them
> as two new dollar-sign functions - elements to be extended by Prototype
> geniuses. :-)
>
> makeText(string) as $T() - return text node element
> Does just what it says... I'm sure someone could extend it nicely when
> via Prototype.
>
> (example) var x = $T('hello world');
>
>
> xElement(tagname) as $E() - return DOM element
> * return element, when tagname is a string - via ".createElement()"
> * return (deep) clone, when tagname is already a DOM element
>
> $E processes extra arguments for generating DOM trees...
> * When extra argument is an element reference, it's appended to output
> * Extra string arguments become attribute/value of output.
> * [Exception] When the only extra argument is a string, it is appended
> as a textnode.
>
> (example 1) var x = $E('p','this is a paragraph');
> (example 2) var x = $E('a','href','http:/\/cnn.com',$T('this is a
> link'))
>
> What do you think and where do I post these; should I include them as an
> attachment here?
>
> - Best O'Luck!
>
> bemson
>
>
>
> **********************************************************************
> Please be aware that, notwithstanding the fact that the person sending
> this communication has an address in Bear Stearns' e-mail system, this
> person is not an employee, agent or representative of Bear Stearns.
> Accordingly, this person has no power or authority to represent, make
> any recommendation, solicitation, offer or statements or disclose
> information on behalf of or in any way bind Bear Stearns or any of its
> affiliates.
> **********************************************************************
> _______________________________________________
> Rails-spinoffs mailing list
> [email protected]
> http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
>
>
>

_______________________________________________
Rails-spinoffs mailing list
[email protected]
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs

_______________________________________________
Rails-spinoffs mailing list
[email protected]
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs

Reply via email to