similar to: Populating text_tag with serialized data

Displaying 20 results from an estimated 500 matches similar to: "Populating text_tag with serialized data"

2007 Feb 18
2
SerializationTypeMismatch in Production Mode
In production mode, I keep getting this error the 2nd time it loads a page with a serialized attribute: ActiveRecord::SerializationTypeMismatch (answers_container was supposed to be a Array, but was a NilClass): /vendor/rails/activerecord/lib/active_record/base.rb:1964:in `unserialize_attribute'' In development, it works fine. In fact, if I set to false config.cache_classes in
2006 Jan 02
1
Dealing with collections of model objects
For an application I''m writing I have a model object, "Answer", many of which are associated with a "Request" object. A user will need to answer many questions, each of which is stored in an Answer object that is associated with their request (Request has many Answers). Is there an easy way to create and then validate each of these Answer objects? I basically want to
2006 Dec 01
2
more_like_this not working?
Hi all, using ferret 0.10.13 and aaf trunk, i cannot get more_like_this to work. I read other posts on this forum related to that, but that did not solve it. I have a model Question with a field question_text. I do: ----------------------------------------------- >> q = Question.find(:first) >> q.more_like_this NoMethodError: You have a nil object when you didn''t expect
2006 Apr 24
4
Does Rails need more useful form helpers?
I have been using rails professionally for only a month and a half now, but I am continually running into problems with form helpers and accessing multiple objects on a single page. To whit: 1. While text_field and text_area and such all support the :index option, the select helper does not. 2. When appending the text ''[]'' to a helper''s object name, the id is
2007 Mar 20
4
rhtml plugin needed
Hi ! Is there any rhtml plugins for Eclipse ( or ) Radrails editors ? Pls , suggest me ! -- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To
2006 Feb 09
6
troubleshooting an observe_field
Hi, I''ve got a live_search field in a partial that is on several different pages. On all pages, except 1, it works fine. On the page it doesn''t work on, it seems it never executes it action. Here''s my observe_field code inside the partial: <h1><label for="searchtext">Live Search:</label></h1> <%= text_field_tag :searchtext
2006 Mar 24
4
validate if different?
Hi, I seem to remember seeing the equivalent of saving only if all attributes are different. I can''t seem to find that now in the API or the agile book. I''m using the acts_as_versioned and only want to save if the input is different. Thanks, Steve http://www.smarkets.net -------------- next part -------------- An HTML attachment was scrubbed... URL:
2005 Dec 22
3
help with unless
Hi, I need a fresh set of eyes to look at this bit of controller code and tell me why I might be getting an error message: lookup = Profit.find(:all, :conditions => [ "user_id = ? AND product_id = ?", uid, pid]) unless lookup.empty? if (lookup.updated_on > 360.minutes.ago) return end end If lookup is empty, then I
2005 Dec 21
7
use of SET command in find_by_sql
Hi, I''m trying to execute something like this method in a model: def self.sql_for_rankings() sql = "SET @counter:=0;" sql << " SET @counter:=0; SELECT *, @counter:=@counter+1 AS rank FROM testscores. " find_by_sql(sql) end Where the new rank column is a kind of autoincrementer inside of
2006 Mar 31
4
javascript help
Hi list, I have a list of tags. I want to be able to click on a tag and have that tag name populate an input field. I think delicious used to allow you to click on existing links to tag your bookmark similar to this (moving instead to auto_complete). My guess is the code looks something like this.... <form> <input type="text" name="all" id="discover"
2009 Mar 15
4
php 5.2
Hi, Is there any news about CentOS 5.2 updating to php 5.2? Best Regards, Melinda Odom Design Hosting, Inc. Web Design, Web Hosting, & Ecommerce Solutions 479-471-0891 CST info at designhosting.biz http://www.designhosting.biz
2009 Mar 13
7
rails, passenger, and images
Just switched over to passenger for development and production for my rails app. Liking it so far. My problem is my image_links, stylesheet_tag_links, and javascript_tag_links are all adding "http://localhost:3000 to the generated links. I got around the stylesheet and js links by not using the helpers. I can access my all of my assets directly via http://dating.local/stylesheets/all.css,
2006 Apr 27
2
centos 4.2 upgrade
Hi, Which one of these listings would I put in my yum.conf file to upgrade my centos 3.6 to centos 4.2? http://mirror.centos.org/centos/4.2/os/ alpha or ppc? Sincerely, Melinda Odom www.designhosting.biz 479-471-0891 -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.385 / Virus Database: 268.5.0/325 - Release Date: 4/26/2006 -------------- next part
2005 Aug 07
8
Ajax forms and redirects
Here is an example that seems perfect for Ajax that I have not seen implemented nor can figure out how to do it. I am hoping someone can give me some pointers. On the sign-up page, I would like to do my validations (password length, username uniqueness,etc ) Ajax-style. But if all validates, then redirect to the success page. The combining of redirection to a new page with Ajax is throwing me.
2007 May 08
4
help with rspec''ing controller
Hi, I''m a rspec newbie. I''m having trouble with rspec''ing a simple controller to Create a record. I''ve tried a couple of approaches and still get errors: Mock ''remedy'' expected :save! with (any args) once, but received it 0 times -or- Mock ''Remedy'' received unexpected message :save with (no args). Here are my two
2006 Apr 17
3
help debugging an error
Hi, I''ve started getting an error I can''t debug. The error doesn''t generate anything in my development log. A breakpoint set right at the beggining of the controller method does not get triggered. It happens on a form submission. I can make changes to the object model from with the console, but not on this form submission. I thought maybe it was routing, because I have
2005 Oct 31
2
Inplaceeditor and a tooltip on mouserollover?
on mouseover when using inplaceeditor it highlights in yellow. Great. However, I want to also show a tooltip inside this div on mouseover. Specifically, when a user is over editable text, besides the yellow background, I want to display next to it a "delete" link. One of the things I''ve tried is this: <script language="JavaScript"> new
2005 Dec 26
2
resorting a dataset
Quick question to see how I might re-sort an Activerecord data set. Let''s say I have this table: tablename: testscores | id | student | score | avg_for_year 1, steve, 85, 82 2, tom, 84, 92, 3, jim, 92, 95 In my controller, I have something like: t= Testscores.find(:all, :order => "score DESC", :limit => 2) ...where it would return the records for Jim and Steve.... My
2006 Apr 28
4
os update with plesk
Hi, I have plesk server administration 7.5.4 on my server and am wanting to upgrade to plesk 8. Plesk 8 supports Centos 4.2 and the notes on the 4.2 readme say: http://mirror.centos.org/centos/4.2/readme If you know what you are doing, and absolutely want to remain at the 4.2 level, go to http://vault.centos.org/ for packages. If you follow the other link listed in that doc it goes to the
2005 Oct 26
2
Troubleshooting inplace editor
I can''t get the inplace editor to do anything for me. The output appears as regular formated, unclickable text. Maybe I am missing something simple. 1. I just downloaded script.aculo.us <http://script.aculo.us> 1.5_rc3 and copied it to my javascript folder. 2. To set up a simple test, I created a new test page containing only the copied from demo1 from the script.aculo.us