Все вопросы: [ruby-on-rails-plugins]
73 вопросов
таблицы аутентификации openid и что они означают
Я установил плагин ruby on rails "open_id_authentication".После запуска миграции он создал две таблицы «open_id_authentication_associations» и «open_id_authentication_nonces». Кто-нибудь знает, что эти таблицы делают и как они используются? Спасибо
Gem / плагины Ruby Geolocation
Какие есть доступные (лучшие) гем / плагины геолокации на основе IP-адреса Ruby? Чем они отличаются друг от друга с точки зрения функциональности, производительности и простоты использования (например, взаимодействуют ли они с веб-службой или требуют отдельной базы данных и т. д.)? Я н...
Сохранение файла в выбранном пользователем месте с помощью рельсов
Мы разрабатываем функцию, позволяющую пользователям сохранять загруженный файл.Мы изо всех сил пытаемся получить всплывающее окно, в котором пользователь может выбрать целевое местоположение / папку для сохранения своего файла.Можно ли этого добиться с помощью рельсов?
Где мне вставить свой URL-адрес Rails в автозаполнение JQuery, чтобы ссылаться на нужный мне набор данных?
Где я могу ссылаться на свой URL-адрес контроллера (Rails), чтобы показать нужный набор данных в автозаполнении через JQuery?Вот моя голова: <script src="http://code.jquery.com/jquery-latest.js"></script> <script type="text/javascript" src="http://dev.jquery.com/view/trunk/pl...
Rails - предоставление лицензионного ключа плагину на основе имени хоста
Я использую New Relic для Rails, но New Relic нужен только для мониторинга моей единственной производственной среды.Однако у меня есть промежуточный сервер, который также работает в производственном режиме.New Relic определяет оба экземпляра как работающие экземпляры prod моего приложения (как и...
How to customize layouts in Goldberg CMS?
I maintain legacy website running on Ruby on Rails and Goldberg CMS. Some things that are really trivial to do in Rails are difficult to implement in Goldberg. For instance: I want some content pages created by Goldberg CMS to use non-standard layout (currently, every Goldberg page uses default a...
Why is it bad to use models as enumerations?
I was just watching a preview of a session at Aloha on Rails called "You're Doing it Wrong". In the short preview, he mentions using ActiveRecord models as enumerations (I assume he means plugins like enumerate_by). This seems like reasonable idea to me, what are the problems? Is it just the ove...
Rails Plugins
Is it possible to include view code in a plugin, such that an app using the plugin can simply call reference the view code like it might reference one of its own partials. Am I off track here or are there good examples of plugins which do this..
How to validate selects / inserts are hitting the right server with MySQL Master/Slave
I've got a rails app using the master_slave_adapter plugin (http://github.com/mauricio/master_slave_adapter/tree/master) to send all selects to a slave, and all other statements to the master. Replication is setup using Mysql master / slave. I'm trying to validate that all the SQL statements ar...
Rails App Notification Plugins
Can anyone recommend some rails plugins that would allow me to register various notification against models that could be linked to a set of templates to format emails (and possibly other). Ideally the plugin could be referenced in one line from each model and the notification format could be pa...
Aliasing activerecord methods inside plugin
I'm trying to write a plugin that aliases some methods in ActiveRecord in the following fashion: class Foo < ActiveRecord::Base include MyOwnPlugin acts_as_my_own_plugin :methods => [:bar] def bar puts 'do something' end end Inside the plugin: module MyOwnPlugin def self....
resource_controller get rid of setting flash notice?
I am talking about rails resource_controller gem plugin here: Basically when I am doing json format, I would like to completely suppress the flash notice if possible, trying to call flash "" will fail, while calling flash[:notice]="" doesn't look really nice either. Is there some better approach?
Rails: when would one use shopping cart software when developing a webstore with rails?
For someone who would like to develop a webstore type web application, and at the same time learn about web development with rails, would you recommend using a shopping cart service or starting from scratch? I guess I'm not entirely sure exactly what shopping cart software is either, so if someon...
'Stack level too deep' error in engine-like plugin with globalize
I have built an engine-like plugin thanks to the new features of Rails 2.3. It's a 'Product' module for a CMS, extrapolated from a previously existing (and working) model/controller. The plugin relies on easy_fckeditor and on globalize (description and title field are localised), and I suspect th...
Ruby Railroad diagram generator fails with NoMethodError for [] in Enumerable::Enumerator
I'm trying to generate model diagrams using the railroad gem. I have managed to generate a diagram for a different app, but I'm trying to get my head around some "legacy" code, and keep running into problems. I know very little about ruby or rails, so any help would be appreciated... Basically...
Using attachment_fu, how do you edit an existing photo, update only thumbnails, and leave original unedited?
After a photo is uploaded and created using attachment_fu, is there a way to edit just the thumbnails and leave the original as it is? I understand how to do the resizing or cropping, but it's applying the edits to all of the thumbnails and the originals, which is how I'm sure attachment_fu was ...
Plugin to use Ruby on Rails Simple I18n backend with translations overridable in the database?
Hoping some learned Rails developers here can recommend an existing Ruby on Rails plugin or gem that allows you to continue using the Simple I18n backend whilst allowing you to optionally specify translations in the database. Here's why: I have one Rails app used for many websites. For the exa...
pros/cons of a ::Base class (rather than acts_as_foo)
Rather than an acts_as_foo syntax**, I'm toying with the idea of extending ActiveSensor::Base < ActiveRecord::Base and then extending this base class with all the errors/validations/class methods/whizbangs. Proposed: #active_sensor.rb gem module ActiveSensor include ActiveRecord autoloa...
Virtual attributes in plugin
I need some help with virtual attributes. This code works fine but how do I use it inside a plugin. The goal is to add this methods to all classes that uses the plugin. class Article < ActiveRecord::Base attr_accessor :title, :permalink def title if @title @title elsif se...
How to convert the following ruby code into Rails plugin?
#!/opt/ruby_ee/bin require 'rubygems' require 'twitter' require 'net/http' require 'uri' require 'httparty' module FbTweet def FbTweet.tweet(url) bitly_url = Bitly.shorten(url) httpauth = Twitter::HTTPAuth.new('username', 'password') ...
What Ruby on Rails plugin/gem would you recommend to implement widely-used blog publishing API (Atom, MetaWeblog, etc) in a custom blog
I have a custom-made blog running off RoR and I would like to implement publishing API. I would prefer to use a widely-used API - e.g. Atom, MetaWeblog, etc - so that I can post to my blog from almost any other web service - flickr, youtube, pixelpipe, etc.
A copy of ApplicationController has been removed from the module tree but is still active
Whenever two concurrent HTTP requests go to my Rails app, the second always returns the following error: A copy of ApplicationController has been removed from the module tree but is still active! From there it gives an unhelpful stack trace to the effect of "we went through the standard ser...
Rails Photo Gallery Plugin for 3rd Party Hosting on Flickr or Picasa
I don't want to store photos on the server. I'd prefer to use picasa or flickr, etc. I'm wondering what solutions are popular and work well. I've found: http://code.google.com/p/picasaonrails/ http://code.google.com/p/loupe/ Has anyone tried these? Any alternative suggestions? Thanks all.
rails Subscribe To Comments plugin like wordpress
Is there any rails plugin for Subscribe to comments one like the Wordpress has?? i.e. On the comment form, a checkbox to check whether the commenter would opt-in whether to get email notification when a new comment is added?
Crypted_password is null when using Authlogic to save a user
i'm getting a strange error on my production install when i try and create a new user using AL: ActiveRecord::StatementInvalid: Mysql::Error: Column 'crypted_password' cannot be null: INSERT INTO users especially strange b/c it works as expected on my local box. RUnning Rails 2.3.2 and ruby 1...
How can I turn my Rails app into a plugin?
I am currently developing a cms and want to reuse the functionality in other projects.
Which Rails plugins should I be using?
I learnt rails a couple of years ago out of interest, but now I'm coming back to it because I want to try and build a simple pay-to-advertise niche job site with a few bells and whistles. Many of the rails books I learnt from gave examples of how to build a shopping cart or user authentication sy...
Gem-idea: Automatic spam protection with captcha in before_filter when HTTP-method is post,put or delete
I'm thinking about writing an automatic spam protection system (maybe I will write a public gem) for rails. My concept is to include a helper method in application_controller f.e.: class ApplicationController < ActionController::Base automatic_captcha_redirect(:min_time => 30.seconds :l...
jRails Alternative
do you know an alternative to jrails? It's more or less outdated (uses jQuery 1.5 - now 1.7 is the current release). Does anybody know an alternative? Thanks EDIT: I know how to build the rails helper with jquery allone - but I like the rails helpers, so I dont want to use jquery allone (wi...
What are the benefits of using the Rails gem instead od vendor/rails?
I recently started working on a small personal project in Ruby on Rails, and have run into a few things that I couldn't find definitive answers for. If anyone here is knowledgeable enough to help, that would be greatly appreciated. All of my questions are below: What benefit is there to using ...