Module: ConstructorIORails::Helper
- Defined in:
- lib/constructorio-rails/helper.rb
Instance Method Summary collapse
Instance Method Details
#constructorio_autocomplete(options = {}) ⇒ Object
5 6 7 8 9 |
# File 'lib/constructorio-rails/helper.rb', line 5 def constructorio_autocomplete( = {}) result = %Q|<script type="text/javascript" src="//cnstrc.com/js/ac.js"></script>\n| result += %Q|<script>$(document).ready(function(){ $('##{[:dom_id]}').constructorAutocomplete({ key: '#{ConstructorIORails.configuration.autocomplete_key}' }); })</script>| return result.html_safe end |