I would say wrong is not the right word here.. perhaps not the maximum best practice. It depends on your audience.. if it doesn't make a huge deal to your audience then its not that big of a deal. however if you can afford the resources then using unobtrusive hooks is a best practice and helps keep code maintainable.
asp.net uses html 5 data- attributes to hook up unobtrusive javascript calls to elements.. its quite interesting. On Mon, Nov 1, 2010 at 12:17, Massimiliano Arione <garak...@gmail.com>wrote: > On 31 Ott, 19:44, Parijat Kalia <kaliapari...@gmail.com> wrote: > > Hey guys,r unning into a silly doubt that should so not happen at all! > > > > I have a textarea tag, > > > > <?php echo textarea_tag('hint_box','','size=70x4', > > array('onclick'=>'javascript:alert("yo") ')) ;?> > > > > and the onclick event is failing to render itself in the HTML tag. > > > > Any pointers what I am doing wrong here? > > It's wrong to rely on html inline javascript. > You should move your javascript logic into a javascript file, relying > on javascript events. See http://api.jquery.com/click/ > > cheers > Massimiliano > > -- > If you want to report a vulnerability issue on symfony, please send it to > security at symfony-project.com > > You received this message because you are subscribed to the Google > Groups "symfony users" group. > To post to this group, send email to symfony-users@googlegroups.com > To unsubscribe from this group, send email to > symfony-users+unsubscr...@googlegroups.com<symfony-users%2bunsubscr...@googlegroups.com> > For more options, visit this group at > http://groups.google.com/group/symfony-users?hl=en > -- Alex Pilon (613) 608-1480 -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups "symfony users" group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en