Skip to main content
Extending Rails flash
Rails • Asked by Jiri Prochazka
I have in *app/lib/action_dispatch/flash/flash_hash.rb* file this code: class ActionDispatch::Flash::FlashHash def my_method #... end end but when I call it in...

Do I have to publish the source code of a commercial app if I use a GPL licensed gem like prawn?
General Solved • Asked by Drilon Buzuku
Hey Guys, do I have to publish the source code of a commercial app if I use a GPL licensed gem like prawn? Cheers, Drilon

Add Students to a class in a HABTM relationship !
Rails • Asked by John Sanderbeck
I have an app designed that I have classrooms and I want to "enroll" students in the class en mass. For example I want to be able to search by name and either add by an enroll or add button or a c...

Multiple Devise Users sharing a dashboard
Rails • Asked by Stephen Sizer
Hi, I have currently two Devise models Company and Contractor. When they sign in I want to redirect them to a dashboard page. At the moment I have a before_action on the dashboard controller ...

Rails 5.0 - How to implement in-place editing without using best_in_place gem
Rails • Asked by Mike Whitehead
I'm building an Events site using RoR which I've just upgraded to v5.0.1 (not moving to 5.1 just yet). My events show page has a comments section at the foot of the page which, so far, only has a c...

Running multiple Rails versions
Rails Solved • Asked by Jiri Prochazka
Hi guys (and ladies if any), I have installed Rails with rbenv (recommended), but now because of significant changes between 5.0.1 and 5.1 versions, I want to start a new project with 5.1 (becau...

rails5 + heroku + cloudfront + fonts
Gems / Libraries • Asked by Sz M
I tried to configure a rails5 app (deployed on heroku) with cloudfront for assets and fonts. I could make it work for the assets, then I tried to add the config for the fonts as well, but I just sc...

Nested attributes
Rails Solved • Asked by Giancarlo Corzo
Hi All, I'm working with nested forms and I'm stuck trying to create the two models and the controller to handle this association. My models following this structure: Survey -> recipients

Styles not rendering
CSS Solved • Asked by Miguel
Hey guys, So I'm following [a tutorial](, and around the 1 hr mark, he starts adding the styles. When I tried to reproduce it, it would n...

Devise - logging on with something other than email
Gems / Libraries Solved • Asked by RJ McCollam
I have followed the instructions on this page to allow signing in with some...

How to use In-App Notifications as an activity feed?
Rails Solved • Asked by Adrian DeGus
I worked through yesterday and it works great. I tried to use this same system create activity feeds for my different models, but ran ...

Two Forms/Two Controllers/One Page: Passing Instance Variables, Routing, and Error Handling
Rails • Asked by Michael Becco
So... I'm having a higher level conceptual gap on how to deal with a scenario in which a form errs out on a page that has two forms relating to two different controllers. My first knowledge g...

Email Stripe Receipts
Rails Solved • Asked by Steve Polito
Firstly, thanks for the great Stripe tutorials! I just finished implimenting basic subscriptions on my rails app. However, I do have a few questions regarding emails. **Will Stripe automatically...

Access Rails constants from Webpack-managed JS
Rails Solved • Asked by Alex Musayev
I'm just starting to use Webpack with Rails, and have a question. Let say there is a constant defined in Rails application. What could be a proper way to access this constant from JavaScript? Assum...

Colorbox & Turbolinks load
Javascript • Asked by Thomas M
Hello, Rails 5.1.0 & Turbolinks5 & Jquery3.1.2 here I'm trying to make jQuery Colorbox works with dynamicly loaded elements (using ActionCable) with no luck. With the implementatio...

3rd party integrations using Oauth/omniauth
Rails Solved • Asked by Masud Hossain
When creating a facebook login, you put `user = User.from_omniauth(env["omniauth.auth"])` inside `sessions_controller.rb` , so when a user goes to /auth/facebook it will prompt them to login via fa...

Watchlist Toggle
Site Feedback Solved • Asked by Ron Huppert
Hi Chris, Not sure what the origianal intention was regarding the "watch later" button other than marking the specific episode, but I wondered if it could be added to the episode filter options....

Getting googlemaps javascript and turbo links working together
Javascript • Asked by Chris Rockwell
Hey Chris - been struggling with this off and on for a bit now. Just trying to add basic google maps using the javascript API (not the gems) to a rails 4.2 app and am having all of the various is...

How do I Geocode location with either address or Lat / long
Rails Solved • Asked by Joe Minock
I'm building a portfolio app where a user can share all of the locations that they like to work from. A location can be a home, office, coffee shop, park or some random place in the wilderness. Giv...

How do I give Users the option of either selecting from a dropdown menu or inputting their own and adding it DB for other users
Rails Solved • Asked by Omar Khedr
I apologize for the newbie question. But, I've been trying to create a special type of association and all my efforts have been failing. I would like to give users the ability to select their home ...