similar to: has_one not working as expected?

Displaying 20 results from an estimated 4000 matches similar to: "has_one not working as expected?"

2006 Mar 01
5
scaffold.css and Rails tutorial problem
In iteration D.1 on page 109 I am not getting a styled error message box displayed at the top of the checkout as described in the tutorial and I cannot seem to discover where I have erred. The scaffold.css is copied from the pragmatic programmers site: #-------------------------------------------------------------------- $ cat public/stylesheets/scaffold.css body { background-color: #fff;
2006 Jul 20
7
How do you use :message with validation?
If I do validates_uniqueness_of :name, :message => "It''s not uniqueeee!!!" then how do I have it display that message when the check fails? -Ben Lisbakken -- Posted via http://www.ruby-forum.com/.
2006 Jan 27
17
Multiple Model Validation
Hey All ! I have a form which contains two models. I would like both models to be validated, but have their validations aggregated on the page. If I do: <%= error_messages_for(:model1) %> <%= error_messages_for(:model2) %> It puts two big validation blocks on the page. I would like all the errors from both models, but only in one validation box. Is this possible ? All my attempts
2006 Jun 13
7
help with ''error_messages_for''
Greetings, I''m in the throws of deploying an app on site5, and I''m getting strange errors. I think I might need to understand how error_messages_for works. I get a pretty standard looking error: " You have a nil object when you didn''t expect it! You might have expected an instance of ActiveRecord::Base. The error occured while evaluating nil.errors Extracted
2005 Oct 10
3
Scrollable DIV causes flicker in FF - SlideDown & SlideUp
I have a fixed height scrollable div inside another div that controls the slideDown and slideUp effects. This causes a really bad flicker in Firefox (1.0.7) for the entire duration of the slide down and up. While on the other hand it works smoothly in IE (except that on a slideUp it causes a last second flash that shows the entire div). Any ideas on how I can fix this? Thanks.
2006 Mar 27
3
Validation - How to pop up error messages
Hi, I''m trying to "validate" the input provided in the login form to see if "username" is entered or not? How do i do this ? In the model i have done like this validates_presence_of username, :body, :message => "Missing required field" But I''m not this message (Missing required field ) getting printed at all? How do i print this? Do i need
2006 Dec 12
2
Error message translation
I have a problem with translation of english phrase when an input error occurs. When I put: error_messages_for("registratie") above my view. I get the error: "xx errors prohibited this registratie from being saved". The problem now is, the site is for dutch customers and I would like to translate this to a dutch phrase. I know I can translate the individual fields with the
2014 Mar 13
1
migrating from samba 3 to samba 4
Hi all, after the news that samba 4 is now supporting user lockouts after bad password attempts we need to plan our roadmap on migrating from Samba 3 to samba 4. We currently have Samba version 3.0.7-1.3E.1 installed with (passwd) database as a backend. I would appreciate if anyone can guide me on the migration process. Our old server Centos 4.4 Samba 3.0.7 (Master browser)
2006 Mar 02
2
Help with routing error.
Ok .. if you are sensitive ... stop reading. I am totally new to setting up CGI. I am getting a routing error. Would someone be kind enough to help me? Please? Here is my form ... <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
2006 Jun 16
5
Menu using Scriptaculous Effects = OnMouseOver bug
I am trying to achieve a Flash-like menu with OnMouseOver effects on 3 divs below. Unfortunately, the javascript resets when the mouse is rolled over the text and if you go mouse crazy on the divs, the script seems to remember where it cut off, and doesn''t roll down completely afterwards. Is it a good place to ask for help? I couldn''t find any Scriptaculous forum (only
2008 Jan 31
3
presenting validation errors via fbml?
Hi Facebookers, Is there a helper or suggested approach for presenting validation errors on an fbml form? Something to translate rails error markup to fbml:error markup? thanks Joel
2006 Jul 16
3
RJS problem
I have an odd problem while trying to use a simple rjs. _test.rjs : page.alert "test" test.rhtml: <script><%=render_partial(''test'')%></script> When I am attempting to view controller/test the page comes as if it was a text file. So i am actually seeing: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2006 Mar 30
4
possible scriptaculous bug
I have two sortable lists, one after the other. I can drag from the first to the second but not from the second to the first. The behavior is consistent if n > 2. For example, I can drag from 1 to 2, 3 or 4 from 2 to 3 or 4 and from 3 to 4, but not in the reverse order: I can''t drag from the 4th list to anything (besides itself). From the third list I can drag only to itself and 4.
2008 Apr 20
2
mod_rails showing plain text instead of actual page
hello! i got this forum powered by apache and mod_rails lately when i create / edit posts, i get plain html text showing up instead of the actual page. here''s what i see: -- Content-Type: text/html; charset=utf-8 Set-Cookie: _mysite_session=BAh7CzoOcmV0dXJuX3RvMDoKdGl0bGV7BmkVdToJVGltZQ2IDhuAK1UeADoL %250AdG9waWNzewZpBnU7Bw2HDhuA2%252FZJ7zoJdXNlcmkGIgpmbGFzaElDOidBY3Rp
2006 May 11
1
Doctype -- utf-8 -- html vs xhtml
I was simply trying to write the DOCTYPE line at the top for UTF-8 and got confused. What doctype do I use with rails for utf-8 files? If I put in all the damn closing tags on paragraphs and hr and br and all that will the stuff pass xhml inspection, or will rails insert something I haven'' yet noticed. Warren -------------- next part -------------- An HTML attachment was
2005 Dec 16
12
validates_presence_of not working
Hi, I''m new to ruby and rails. I just created a simple update page and the update works fine if all form fields are filled in. However there is one field that should never be allowed to be blank. So I put this in my model: class Topic < ActiveRecord::Base validates_presence_of :dr_title validates_length_of :dr_title, :minimum => 1 So, when I submit the form with a blank
2013 Jan 07
4
JSON::ParserError in controller
Hi All I''m trying to build an application which requires to scrap information from a webpage. On trying to perform the action, I get an error while trying to convert the html data to JSON. Has anyone experienced this before and if so can you please tell me how to solve this problem ? Please see below for code snippet and error log. Thanks in advance Anush require
2014 Mar 04
1
User account lockout - bad password with Samba4 ?
Hi guys, I am so thrilled by samba 4 it makes me go to bed smiling J Here is my setup. Server ************ Centos 6.5 Samba 4.1.4 Clients ************* Windows XP, 7 & 8 Question: Is account lockout supported with samba4 ? I cannot seem to get the users accounts to lock when they type their passwords incorrectly. The rest of my GPO's work. Folder redirects work
2014 Feb 21
3
Please share your mail setup with me if you are running samba4
Hi Guys, I had no luck so far getting openchange installed onto samba 4.1.4 and wondered if I am on the right track here regarding emails for users. I will appriciate it if anyone can share their setups with me so I can estimate what will be the best way forward. The plan so far. Run Samba4 as a file server. (this is working in a test enviroment) Run Samba4 as a DC with Active Directory
2010 Aug 18
7
error_messages_for doesn't work
I''m having a problem, ''cause I wrote the following line in my model "Hi": [code] validates_numericality_of :phone, :only_integer => true, :allow_blank => false, :message => "must be a number" [/code] And in my "new" view, I put: [code] <%= error_messages_for :oi, :header_message => "Erro ao cadastrar