[Rails] Memcache and Rails - Storing String as values.

2012-08-07 Thread Jimish Jobanputra
Hello all, I have been using Memcache with my rails application to store certain key value pair I am using Dalli gem for the same... So Here's what i do from console: require 'dalli' dc = Dalli::Client.new('remoteserver:11211') dc.set('example_link', "http://www.google.com";) => true value

[Rails] Creating ToDo List App

2012-08-07 Thread Emeka Patrick
Hi, New Rails user here trying to create a basic todolist app in rails 3.2.6 and running into some foreign key issues. Here's what I did... I generated scaffolds list title:string & task description:text listname:string Next, in order to link the listname for Tasks and the list titles in the Li

Re: [Rails] uninitialized constant ActiveResource::UnauthorizedAccess

2012-08-07 Thread Rafi A
Hi, This is resolved. I copied the 'activeresource-3.0.0' gem folder from the source folder of rails3 and pasted under the 'config/initializers' folder of my rails3 application. So the below code snippet available in application_controler.rb file is working fine as expected. class ApplicationCont

Re: [Rails] Re: Rails' inflections are messy

2012-08-07 Thread davidcelis
Guys, lets keep in mind that I meant for this discussion to be about how the inflection rules themselves are bad. Not how they're used internally with Rails, but how the file that defines these rules is an utter mess. On Thursday, August 2, 2012 8:30:33 AM UTC-7, paulie wrote: > > index: GET /me

[Rails] Re: Nested attributes from multiple models on form. Rails 2.3

2012-08-07 Thread masta Blasta
masta Blasta wrote in post #1071551: > I have two models > term > term_versions (build from acts_as_versioned) > > They are related but for all intents and purposes different models. > > 'term_versions' has this association not available to 'term': > has_many :technical_definitions, :dependent => :

[Rails] Re: how to maintain RTL version of stylesheets with rails asset pipeline?

2012-08-07 Thread Jeppe Liisberg
Hi guys, Since no-one could answer me the way I wanted, I went ahead and created a solution: https://github.com/monibuds/stylesheet_flipper It's on rubygems.org, currently in version 0.0.2 and it's in production on app.monibuds.com. If you like the solution, feel free to upvote my answer on

Re: [Rails] How transferable is a Ruby on Rails CMS?

2012-08-07 Thread Hassan Schroeder
On Tue, Aug 7, 2012 at 8:06 AM, Paul T. wrote: > We are looking at hosting the site with a separate company, and I just > wondered if this would actually work - how well known is Ruby on Rails? > Would a different technical team actually be able to understand the CMS > to be able to provide suppo

[Rails] How do I force link_to/form helpers to use the superclass name in the path instead subclass?

2012-08-07 Thread Mohamad El-Husseini
I want my helpers to generate paths using a superclass instead of the subclasses. Assuming I have Owner and Member that both inherit from User, rails will use the current objects class name when generating paths: Let's say current_user is a mod: <%= link_to current_user.name, current_user %> wi

[Rails] How transferable is a Ruby on Rails CMS?

2012-08-07 Thread Paul T.
Hi, I am looking into a new website, and a couple of potential designers have recommened using a CMS system built on Ruby on Rails ... one bespoke and one using a customised version of Refinery. Both have said that we will own all the coding, and so will in theory have the flexibility to host the

[Rails] Nested attributes from multiple models on form. Rails 2.3

2012-08-07 Thread masta Blasta
I have two models term term_versions (build from acts_as_versioned) They are related but for all intents and purposes different models. 'term_versions' has this association not available to 'term': has_many :technical_definitions, :dependent => :destroy accepts_nested_attributes_for :technical_de

[Rails] Re: How to encrypt Ruby script..

2012-08-07 Thread Robert Walker
Radhames Brito wrote in post #1071531: > The right question is, "How do i obfuscate my ruby source code ?". > Ruby is interpreted and seems like you would like to have something like > a > compiled binary or a bytecode. All ways I know about of doing this are > payed. > > http://rubyencoder.com/ >

Re: [Rails] how to do render partial on jquery ajax success method with rails 3

2012-08-07 Thread Walter Lee Davis
On Aug 7, 2012, at 9:43 AM, Manish Nautiyal wrote: > That is a .js file. And so, if you want it to also include interpolation, using erb syntax, you have to tack .erb to the end of the filename, and you have to put the file in a location where it will be interpreted (hint: not in /public/javas

Re: [Rails] how to do render partial on jquery ajax success method with rails 3

2012-08-07 Thread G S RAO
You need to know the flow first if u write .erb file it will execute by interpreter and only html response will served to client side browser . But you are trying to execute the ruby code from javascript which will not possible. so it is considering as text and displaying that. anyway request is

[Rails] Re: how to do render partial on jquery ajax success method with rails 3

2012-08-07 Thread Manish Nautiyal
That is a .js file. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To unsubscribe from this group, send email to rubyonr

Re: [Rails] how to do render partial on jquery ajax success method with rails 3

2012-08-07 Thread Walter Lee Davis
On Aug 7, 2012, at 7:03 AM, Manish Nautiyal wrote: > I'm using rails 3.2.1 with jquery for an ajax call. > > My juqery code is : > > jQuery.ajax({ >url: "/org_pages", >data: 'org_id='+ org_id, >type: "POST", >success: function(resu

[Rails] Barcode Generating With Label On Canvas by using Barby gem

2012-08-07 Thread saritha chakilala
UNDEFINED METHOD REGISTER ERROR IN THE FALLOWING CODE *** Hi all, I am trying to generate barcode(including its name as label at the bottom of barcode image for easy understand with out scanning by barcode scanner). For this I am Using barby, chuncky_png, rmagick gems. I am using the

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread radhames brito
On Tue, Aug 7, 2012 at 5:33 AM, lokhande.shrik...@gmail.com < lokhande.shrik...@gmail.com> wrote: > Hi guys, > > Can any one tell me how to encrypt one ruby script.. ? > > Thanks- > Shrikant > > The right question is, "How do i obfuscate my ruby source code ?". Ruby is interpreted and seems like y

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread Peter Hickman
Ruby does not have an "encrypted mode" You asked "Can any one tell me how to encrypt one ruby script", you got the answer to your question Describe the problem you are trying to solve rather than making things up (such as encrypted mode ruby) Puts the RHCE certificate in perspective if you didn'

[Rails] RoR Architecture Review -- Kann uns da jemand helfen?

2012-08-07 Thread Michael Maretzke
Hallo RoR-Gemeinde, ich bin auf der Suche nach einem einzelnen Architekten, einer Agentur, einem Dienstleister, einem ..., der uns hilft / die uns helfen einen Architektur-Review unserer RoR-Plattform durchzuführen. Wichtig ist, dass wir einen Experten bekommen, der tatsächlich schon Skalierung

[Rails] how to do render partial on jquery ajax success method with rails 3

2012-08-07 Thread Manish Nautiyal
I'm using rails 3.2.1 with jquery for an ajax call. My juqery code is : jQuery.ajax({ url: "/org_pages", data: 'org_id='+ org_id, type: "POST", success: function(result){ jQuery("#image_center").html("<%= escape_j

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread Michael Pavling
On 7 August 2012 11:46, Shrikant Lokhande wrote: > Yes its cool,,, but i want to run one ruby script and script having > confidential info. > So i need run that in encrypted mode. Drip-feeding information like this is very frustrating. http://www.catb.org/esr/faqs/smart-questions.html (tl/dr:

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread Valery Kvon
)) On 07.08.2012, at 14:43, Michael Pavling wrote: > On 7 August 2012 11:36, Shrikant Lokhande wrote: >> Its encripted but its not running.. > > Why would it run? It's no longer a Ruby file, it's *encrypted*! > -- You received this message because you are subscribed to the Google

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread Shrikant Lokhande
Yes its cool,,, but i want to run one ruby script and script having confidential info. So i need run that in encrypted mode. Regards*,* Shrikant Lokhande RHCE | Linux Admin | Ruby on Rails Deployment Pune | MH | India. M.+91-9373920803 http://shriikant.blogspot.com/ *http://linux-fundamentals.bl

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread Michael Pavling
On 7 August 2012 11:36, Shrikant Lokhande wrote: > Its encripted but its not running.. Why would it run? It's no longer a Ruby file, it's *encrypted*! -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread Shrikant Lokhande
Its encripted but its not running.. Here is error: rubynetco2.rb:1: Invalid char `\037' in expression rubynetco2.rb:1: Invalid char `\215' in expression rubynetco2.rb:1: Invalid char `\345' in expression rubynetco2.rb:1: Invalid char `\312' in expression rubynetco2.rb:1: Invalid char `\257' in ex

Re: [Rails] How to encrypt Ruby script..

2012-08-07 Thread Peter Hickman
For simple cases I use > openssl des3 -salt -in $SOURCE -out $DEST where $SOURCE is the name of the file I want to encrypt and $DEST is the name of the file the encrypted data will be written to. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk"

[Rails] How to encrypt Ruby script..

2012-08-07 Thread lokhande.shrik...@gmail.com
Hi guys, Can any one tell me how to encrypt one ruby script.. ? Thanks- Shrikant -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To unsubscribe from this group,

Re: [Rails] uninitialized constant ActiveResource::UnauthorizedAccess

2012-08-07 Thread Colin Law
On 7 August 2012 09:25, Rafi A wrote: > Colin, > > Thanks for your reply. Surfed over both sides of Google but not able to get > the apt solution. I am using the below code snippet in Application > controller file so that all the flows will inherit. > > 'rescue_from ActiveResource::UnauthorizedAcc

Re: [Rails] uninitialized constant ActiveResource::UnauthorizedAccess

2012-08-07 Thread Rafi A
Colin, Thanks for your reply. Surfed over both sides of Google but not able to get the apt solution. I am using the below code snippet in Application controller file so that all the flows will inherit. 'rescue_from ActiveResource::UnauthorizedAccess, :with => :render_401' But while invoking the

Re: [Rails] uninitialized constant ActiveResource::UnauthorizedAccess

2012-08-07 Thread Colin Law
On 7 August 2012 09:00, Rafi A wrote: > Hi, > > I am getting the error "uninitialized constant > ActiveResource::UnauthorizedAccess" while executing the rails3 application. > > Below are my package details: > > Rails 3.0.0 > Ruby 1.8.7 > activeresource (3.0.0, 2.3.4) > > Suggestions are welcome!

[Rails] uninitialized constant ActiveResource::UnauthorizedAccess

2012-08-07 Thread Rafi A
Hi, I am getting the error "uninitialized constant ActiveResource::UnauthorizedAccess" while executing the rails3 application. *Below are my package details:* * * *Rails 3.0.0* *Ruby 1.8.7* *activeresource (3.0.0, 2.3.4)* Suggestions are welcome! Regards, Seeni Rafiyullah Khan A, *In Every mome