Data dodania Pytanie
2017-07-02 02:07 Exception Load Errors, for files that exist (even in multiple places?) »
I am finding these errors (via debug) and don't understand why I'm getting them. I'm not sure if I have duplicate files for a reason either. I'm us...
(1) odpowiedzi
2017-07-01 22:07 Check if Active Record table has changed »
In Active Record I can write name_changed? to check if the column name has changed. How do I check if a table has changed? (i.e new records added) ...
(2) odpowiedzi
2017-07-01 12:07 Sinatra doesn't want to say hello »
What could possibly be wrong? I run this file: require 'sinatra' get '/' do "Just Do It" end Server starts up: == Sinatra (v2.0.0) has taken ...
(0) odpowiedzi
2017-06-30 10:06 How to embed an erb.html file within another erb.html file in ruby on rails »
In sinatra I used to just write <% erb :header %> So how do I do something like that in Rails? ...
(0) odpowiedzi
2017-06-30 05:06 undefined method 'id' for nil:NilClass -- edit route won't work »
I'm not really sure why I'm getting the error. Every other route works except for this one. I have also attached the code for my controllers and ...
(2) odpowiedzi
2017-06-29 22:06 Routing And Creating Multiple Pages In Ruby Shoes »
is it possible to create an app in Ruby Shoes (GUI Toolkit) where you can have routing or pages like html? For example, I have a main menu page and wh...
(0) odpowiedzi
2017-06-29 17:06 returning confirmation from paypal api sinatra »
We are creating a paypal express checkout for a business using sinatra. I need to be able to get something returned form the API giving me confirmatio...
(0) odpowiedzi
2017-06-28 20:06 SQL Statement to update multiple columns with multiple where conditions »
So I have the following SQL statement: db.exec("UPDATE products SET product_description = '#{fj_description}' AND personalization = '#{fj_person...
(1) odpowiedzi
2017-06-27 15:06 How to custom layout directory in sinatra »
I have a Sinatra app with multiple layouts, one for admin panel, and one for public. I want to isolate them into their own subdirectory in views: vie...
(1) odpowiedzi
2017-06-27 02:06 Sinatra doesn’t know this ditty »
Would anyone check if I have done something wrong? My app.rb: require 'sinatra/base' require 'sinatra/flash' require './lib/hangperson_game.rb' cla...
(1) odpowiedzi
2017-06-26 16:06 How to test activerecord models outside of rails? »
I have a simple todo sinatra app and want to test activerecord models. Here is the test code ENV['RACK_ENV'] = 'test' require 'test/unit' require 'r...
(0) odpowiedzi
2017-06-26 11:06 Call bash script on button click in a Ruby/Smashing web app »
I was asked to contribute to a simple web app built using Smashing (a Sinatra-based framework). I have a little experience with rails, but I am not fa...
(1) odpowiedzi
2017-06-25 06:06 Datadog APM traces with rack middleware and Sinatra »
I'm using the Rack builder as middleware for my Sinatra application. i'm trying to setup Datadog APM traces for monitoring the Application performance...
(0) odpowiedzi
2017-06-24 13:06 NameError - undefined local variable or method `user_details' for #<Sinatra::Application:0x0000000381bde0>: »
I have a basic Sinatra app when posting form details. I'm getting this error, especially when running on Heroku NameError - undefined local variab...
(1) odpowiedzi
2017-06-23 05:06 Checking if a record exists in Sinatra/DataMapper »
I currently generate a user's profile page using their serial ID, like so: get '/users/:id' do @user = User.get(params[:id]) end This works grea...
(1) odpowiedzi
2017-06-21 20:06 Ruby Sinatra Sessions Across Windows »
I have a quick question about using sessions across different windows. I'm currently trying to create a login screen for a web app that I'm creating a...
(1) odpowiedzi
2017-06-21 17:06 How safe is it to use an ip for running a Sinatra ruby app for an iOS application »
I am building an iOS app and I have an AWS ec2 instance running a Sinatra app for refreshing and swapping a Spotify SDK access token and I am wonderin...
(1) odpowiedzi
2017-06-19 20:06 Ruby Sinatra Sessions in a JSX file? »
I'm a newbie to integrating react + ruby and was wondering if there is a way to access my sessions contents that I stored? For example, in my app.rb,...
(1) odpowiedzi
2017-06-19 09:06 Can I do something like this in sinatra app? config files based on request »
for the following code i'm getting config_file method is not available for the request. How can I do something like setting config file for entire app...
(0) odpowiedzi
2017-06-19 04:06 Prevent users altering information via the back button? »
I made a very simple RPS application, the only issue is that players can currently change the outcome of the game by pressing the back button and sele...
(0) odpowiedzi
2017-06-16 20:06 Why is my layout change not reflecting in a Sinatra/Puma/Nginx production setup? »
I have a website running Sinatra and Puma with Nginx proxying traffic via an upstream to the Sinatra app. Now I have made a change in one of the view...
(1) odpowiedzi
2017-06-16 18:06 Can't seem to run a process in background of Sinatra app »
I'm trying to display a number from an api, but I want my page to load faster. So, I'd like to get the number from the api every 5 minutes, and just l...
(1) odpowiedzi
2017-06-16 01:06 Sinatra Page Not Loading Properly »
I am trying to learn Sinatra. I wrote a script to scrape the job listings from Craigslist and list them on my page (just as an exercise). The output ...
(0) odpowiedzi
2017-06-14 05:06 Why does this code throw an error when used inside the controller, but not the view? »
I have the following model: class User include DataMapper::Resource property :id, Serial property :name, String, required: true property :em...
(1) odpowiedzi
2017-06-13 11:06 Sinatra: Array from JSON into HTML table »
I am new to coding. I work on a project where I get the details from JSON, so created arrays. I want to put the details into an HTML table. Arrays a...
(1) odpowiedzi
2017-06-10 05:06 Sinatra endpoint is working perfectly on localhost, but not found in production? »
I have a weird issue i'm unable to troubleshoot, I get a 404 response body of <h1>Not Found</h1> from my sinatra API when deployed on h...
(1) odpowiedzi
2017-06-08 17:06 How can I check that my automatic deployment worked correctly? »
I'm deploying a sinatra application automatically via git hooks. What are some general tests I can run during deployment to make sure deployment goes ...
(0) odpowiedzi
2017-06-06 21:06 Why does my google refresh token show up locally when i run my app but not on heroku »
I have an app that requires users to sign in with google for I can get their access token and refresh token, when i run it locally I am able to get th...
(0) odpowiedzi
2017-06-05 18:06 Application Error on Sinatra app deployed on Heroku »
I have built an app in a course I was taking in Cloud 9 using the Sinatra framework and deployed it using Heroku. However when I launch the app I get ...
(0) odpowiedzi
2017-06-04 23:06 JavaScript will not run at all »
I have this template as my sinatra layout.erb <!DOCTYPE html> <html> <head> <title>Invoicer</title> <link re...
(1) odpowiedzi
2017-06-04 19:06 Sinatra force logged in on controller »
I have a helper defined in helpers/loggedin.rb that has a function called logged_in? which checks if a user is logged in or not. is there any way I ca...
(1) odpowiedzi
2017-06-03 07:06 Sinatra class instance variable for parallel requests »
I have a method inside my controller class which is called everytime for each request for a specific operation (create in this case) class DeployP...
(0) odpowiedzi
2017-06-02 18:06 Use Sinatra redirect in ternary operator »
Does any one know why saved ? redirect '/success' : erb :signup Throws the following error: syntax error, unexpected ':', expecting keyword_end ...
(0) odpowiedzi
2017-06-01 23:06 Sending JSON Webhook Response »
I'm trying to receive a request from a webservice via JSON and send a successful response message back if the token is correct along with some other i...
(1) odpowiedzi
2017-06-01 05:06 Adding new div to row causes wrapping »
I have some problems with divs in a Bootstrap row wrapping when I don't want them to. I'm designing a Mastermind game (Sinatra/Ruby/JS, for educationa...
(2) odpowiedzi