Rails 3 has some unobtrusive JavaScript which is pretty cool.  But I was wondering what the best way is to include additional JavaScript for a particular page.  For example, where I might have previously done:  <%= f.radio_button :rating, 'p...
I am trying to create a Facebook iFrame app. The app should first show an image and if the user likes the page, he will get access to some content.  I use RoR, therefore I can't use the Facebook PhP SDK.  Here is my iFrame HTML when the user ha...
Is there any way to use a Rails helper method, more specifically, a path helper method within a javascript asset file. This file foo.js.coffee.erb  $('#bar').val("<%= create_post_path %>")   I would love it if I could get from...
I'm new to Capybara and testing on Rails in general, so please forgive me if this is a simple answer.  I've got this test  it "should be able to edit an assignment" do     visit dashboard_path     select(@project.client + " - &#...
I'm using backbone.js and it works great. but the forms I'm creating as a javascript template lacks the rails csrf protection token. How do I add it to templates I'm creating in javascript?...
I am trying to get jquery-ui datepicker to work with highcharts so that a user can select a date an example being   A user selects 10th October  to 25th October   Once the user has selected the dates the highchart should redraw and show the hours for...
I'm making chaining selects with backbone.js by this article http://blog.shinetech.com/2011/07/25/cascading-select-boxes-with-backbone-js/, but got errors, when extending classes.  So, i have LocationsView class:  class Blog.Views.LocationsView e...
I have a form which submit a form via AJAX with :remote => true. Looking at the server log and FireBug, I get the response 200 OK and it returns JSON in the form of:  { "email": "[email protected]"}   then I have these two handlers:  $...
I've looked at this which seems to have no effect on my code. I've tried this which seems to only affect the first checkbox, but doesn't uncheck the checkbox when i click it again anyway.... I've also seen some other ways of doing it...
I'm building a new app with 3.0.0.beta3. I simply try to render a js.erb template to an Ajax request for the following action (in publications_controller.rb):  def get_pubmed_data     entry = Bio::PubMed.query(params[:pmid])# searches PubMed and...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.