0

I have the jquery (gem 'jquery-rails') gem installed. My application.js file is correct. The UI (date picker) does not show up. I updated the HTML code, (id="datepicker") in my input field, but nothing when I click on it. So i downloaded the jQueryUI from the website with a custom theme, but still nothing. Any help installing the jQuery-UI for rails using a custom theme downloaded??

application.js:

//= require jquery
//= require jquery-ui-1.8.23.custom.min
//= require jquery_ujs
//= require twitter/bootstrap
//= require_tree .

the jQuery custom theme came with a css folder and a jquery 1.80 file (which I dont need because I already have) and the jquery-ui-1.8.23.custom.min file which I put into the vendor/javascript folder. I dont want to use this https://github.com/joliss/jquery-ui-rails because it does not support custom themes. Just tell me where to copy paste files so I can get it done quickly

Thanks

2 Answers 2

2

It is not enough to just download the plugin, put it into the assets and change the id of your input. You have to code some javascript like this:

$("#datepicker").datepicker();
Sign up to request clarification or add additional context in comments.

Comments

1

I was unable to get jQuery ui working until I precompiled the assets...

RAILS_ENV=production bundle exec rake assets:precompile

This fixed it for me. (I think deleting the contents of public/assets would also have worked.)

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.