[thelist] JS: createHTMLElement and onclick

VOLKAN ÖZÇELİK volkan.ozcelik at gmail.com
Wed Jul 5 14:10:16 CDT 2006


Although there is nothing wrong in re-inventing the wheel. I think what you
are trying to implement has been done to death in JQuery [1].

Here is a simple example:

var table =
   $.TABLE({ Class:"MyTable" },
      $.TBODY({},
         $.TR({ Class:"MyTableRow" },
            $.TD({ Class:"MyTableCol1" }, 'howdy' ),
            $.TD({ Class:"MyTableCol2" },
               'Link: ',
               $.A({ Class:"MyLink", href:"http://www.example.com" },
                  'example.com'
               )
            )
         )
      )
   );


[1] http://jquery.com/


HTH,
-- 
Volkan Ozcelik
+>Yep! I'm blogging! : http://www.volkanozcelik.com/cre8/blog/
+> Going solo in Turkish: http://www.volkanozcelik.com/donkisot/
+> My projects/studies/trials/errors : http://www.sarmal.com/
+> Sardalya JavaScript Library: http://www.sarmal.com/sardalya/



More information about the thelist mailing list