Stack Overflow

A language-independent collaboratively edited question and answer site for programmers.

  • javascript - Ruby On Rails : AJAX and Submit Request Running Parallely

    stackoverflow.com 18 Oct '17, 8pm

    <%= simple_form_for @video do |form| %> <div class="form-inputs"> <%= form.input :title, id: :video_title %> <div class="row"> <div class="input-field col s12"> <textarea id="textarea1" name="video[description]" class="materialize-textarea"></textarea> <label for="textarea1">Descripti...

  • css - Integrating Bootstrap into Ruby on Rails 5.1.4

    stackoverflow.com 15 Oct '17, 9pm

    git_source(:github) do |repo_name| repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/") "https://github.com/#{repo_name}.git" end gem 'sass-rails', '~> 5.0' gem 'bootstrap-sass', '3.3.7' # Bundle edge Rails instead: gem 'rails', github: 'rails/rails' gem 'rails', '~>...

  • ruby on rails: bootstrap columns don't stack on iPhone

    on rails: bootstrap columns don't stack on iPhone

    stackoverflow.com 17 Sep '17, 10am

    gem 'bootstrap', '~> 4.0.0.alpha6' after deploying my rails app, I encountered weird bug on my iPhone columns don't stack, like the width of the container doesn't shrink or something... the other responsive stuff works - hidden-sm-dowm are hidden on desktop in small window everything ...

  • undefined method deserialize, for work added outside of my rails project

    stackoverflow.com 21 Sep '17, 10am

    We are working on a scheduler to schedule jobs for our rails application. We want to reduce the memory footprint and cpu usage this ruby script takes when it schedules so we are building it as separate project. Items are getting added to queue without any issue, but when they are exec...

  • javascript - Detect if an alert or confirm is displayed on a page

    stackoverflow.com 15 Sep '17, 6am

    If you want to detect if these are being blocked. You will have to do your own thing with the message you will be dispalying but override the native alert/confirm. window.nativeAlert = window.alert; window.alert = function (message) { var timeBefore = new Date(); var confirmBool = nat...

  • Can't update avatar img without page refresh (rails, jquery)

    Can't update avatar img without page refresh (rails, jquery)

    stackoverflow.com 11 Jul '17, 5pm

    Apologies in advance. I'm new to using async calls and I've been struggling with this for a while now. I'd like to update a user avatar image without having to refresh the page after the image has been saved to the user model. <form class="edit_user" id="edit_user_<%= current_user.id ...

  • Rails - Could not find a JavaScript runtime?

    stackoverflow.com 10 Aug '17, 5am

    Note from Michael 12/28/2011 - I have changed my accept from this (rubytheracer) to above (nodejs) as therubyracer has code size issues. Heroku now strongly discourage it . It will 'work' but may have size/performance issues. If you add a runtime, such as therubyracer to your Gemfile ...

  • on rails 3.1 - ExecJS and could not find a JavaScript runtime

    stackoverflow.com 14 Jul '17, 3pm

    I had a similar problem: my Rails 3.1 app worked fine on Windows but got the same error as the OP when running on Linux. The fix that worked for me on both platforms was to add the following to my Gemfile : gem 'therubyracer', :platforms => :ruby The trick is knowing that :platforms =...