Microsoft Exchange service administrators can enable Exchange Web Services (EWS) which is a rather accessible XML API for interacting with...

When you have an Angular directive that transcludes content, you might want to do something in case there is no...

Code snippet tested with Rails 2.3 def index # ... if request.xhr? html = render_to_string(:partial => "list", :layout => false) respond_to...

makandra dev
plugins.jquery.com

SudoSlider is a simple yet powerful content slider that makes no (or very few) assumptions about your markup and is...

github.com

Using this gem, whenever a Capybara test in Cucumber, Rspec or Minitest fails, the HTML for the failed page and...

When your Rails controller action responds with only a simple text, render text: 'Hello' may not be what you want...

Programatically invoke Rails generators Require the generator, instantiate it and invoke it (because generators are Thor::Groups, you need...

If you regularly get ActionView::MissingTemplate exceptions, maybe some bot visits your site requesting silly formats like: http://www.rails-app.com/makandra.html-username-2000...

If you are using Angular and want something like Rails' simple_format which HTML-formats a plain-text input into...

stackoverflow.com

Check out the jsFiddle Demo. CSS .absoluteCenterWrapper { position: relative; /* Declare this element as the anchor point for centering */ } /* Positioning */ .absoluteCenter...

gist.github.com

How to remove/disable the automatic XSS protection helper html escaping for Rails 3. This is probably a horrible idea.

Development environment setup Rails Composer Basically a comprehensive Rails Template. Prepares your development environment and lets you select web server...

faviconit.com

Eduardo Russo was tired of complex favicon creation and created his own favicon generator. It's really easy and allows...

I had to deal with JavaScript Undefined Error while accessing a specific CKEditor instance to fill in text. Ensure everything...

If you have a text that is edited by WSYIWYG-Editor but want some length checking nevertheless, you need to...

If you have a FooController and also have a layout app/views/layouts/foo.html, Rails will use this without being told so.

Rails has always included a scaffold script that generates a default controller implementation for you. Unfortunately that generated controller is...

So you client has asked you to implement a row of buttons to like the URL on Facebook, Twitter and...

github.com

The asset pipeline (which is actually backed by sprockets) has a nice feature where templates ending in .jst are compiled...

fortawesome.github.io

A list of FontAwesome icons in the form of copyable Unicode characters or HTML entities. You might prefer to use...

In order to keep the controllers directory tidy, we recently started to namespace controllers. With the :controller option you can...

snook.ca

CSS3 comes with new unit rem. It works like em but it is always relative to the element instead of...

When two classes implement the same behavior (methods, callbacks, etc.), you should extract that behavior into a trait or module...

In Rails 5 you can say: ApplicationController.render( :template => 'users/index', :layout => 'my_layout', :assigns => { users: @users } ) If a Request Environment is...