I want to save session data in a database using the ActiveRecord :: SessionStore module. I have been looking for this for success for a very long time. Either I do not use the correct search conditions, or I am blind to something very obvious.
I used this require ActiveRecord::SessionStore::Session in my code to enable session processing with an active record. It contains an error in the uninitialized constant ActiveRecord :: ActionDispatch . I assume I installed the actiondispatch module. Am I right?
Please keep in mind that this is my first shot with Ruby-Sinatra. I come from PHP.
So what should I use to force Sinatra to use database sessions using ActiveRecord?
Srisa source share