From: Xavier Noria Date: 2007-12-08T07:04:56+09:00 Subject: Re: Auto Complete using tex input On Dec 7, 2007, at 9:25 PM, Neha Chopra wrote: > But i cant use the tag directly. > I want to use it this way > name="criteria[<%=count%>][data_autocomplete]" size="60" > autocomplete="on"/> > > and i dont know what javascript to pass so that observer gets fired > and > all. This is a starting point, where each component is more or less self- explanatory: return <<-HTML #{auto_complete_stylesheet unless completion_options[:skip_style]} #{text_field_tag tf_name, tf_value, tag_options} #{content_tag("div", "", :id => "#{tf_id}_auto_complete", :class => "auto_complete")} #{auto_complete_field tf_id, completion_options} HTML You create custom HTML elements, and after that delegate in auto_complete_field. -- fxn