similar to: .empty? Method

Displaying 20 results from an estimated 5000 matches similar to: ".empty? Method"

2006 Feb 12
9
CSS in Views
How can I link to a CSS file in one of my view files? -- Posted via http://www.ruby-forum.com/.
2005 May 17
5
Strings, Variables and GetText
Hi, I''m starting to use GetText and have this code: render_text %(<script language="JavaScript" type="text/javascript"> parent.mainframe.onUpdateNew("Gallery <b>#{@media.name}</b> was successfully created.", "#{@media.name}","#{String(@media.id)}","#{@media.media_type}"); </script>) I need to convert
2005 Dec 26
3
probably a very dumb question
why does <%= render_text "hey ya" %> cause ''undefined method `render_text'' for #<#<Class:0x3851120>:0x3851000>'' can i use render text in a template? -- Posted via http://www.ruby-forum.com/.
2007 May 21
4
Just upgraded to 1.0.0, should render_text isn''t working for me
I finally got around to upgrading from 0.8.2 (!!). I had a spec which looked like specify "should render abc123" do controller.should_render :text => "abc123" get :key end With 1.0.0, the new spec is it "should render abc123" do get :key response.should render_text("abc123") end However it doesn''t work, giving me the error: undefined
2006 Jan 07
2
can store array or hash in cookies?
Hi According to rdoc: value - the cookie''s value or list of values (as an array). So, I can use arrays, briliant. But.... It does not work (at least on webrick) I wrote a controller: def check_cookies_first cookies[:chef] = {:value => ["first", "second"], :expires => Time.local (2020)} render_text ":)" end def
2005 Oct 19
6
how to prevent "blinking" when adding an element with an effect
Hi, I add a div to my document and use an effect to make it apear gracefully. Unfortunatly, when adding the element, the element apears shortly, then the effect (slideDown) lets it apear nicely - so the page flickers abit - What is the best practice to avoid it? Cheers, Ron
2007 Sep 29
2
REXML - XML query only returning one (last) result
I''m really new to Ruby on Rails, and I''m trying to read an XML file with REXML. No matter what I try, I am only getting the last result returned from my query. I should be getting 365 results. Here is the code: include REXML require ''rexml/document'' require ''rexml/xpath'' class MakeFootprintController < ApplicationController def index
2005 Nov 18
2
help with User.find() and rendering text
Hi all, I''m trying to do something for a project. Herez what im trying to do. The user name gets passes from the view to the controller. On line2: The user name gets displayed. On line 3: (If this command works the way I think it works, the sad part is I always get it wrong) anyways, The entry in the data base with the given user name gets searched and the user info gets stored in
2006 Apr 03
9
Problem with Windows not finding methods
I am running (testing) a noob-tube for myself as follows: Windows XP SP2 lighty ruby 1.8.x rails 1.1 scgi I have everything working fairly well, but with one minor exception: the actions that I have defined as follows are not found. class MytestController < ApplicationController def index render_text "Hello Nurse!" end def dilbert render_text "Dilbert
2006 Jul 04
1
Select Box problem in the controler with Ajax
Hi, I have a selectbox that updates a given span area when a user selects a value. The selectbox has the option :include_blank => true. The controler will fetch the ID of the selected option in the combo box and sends the description of the item with the same ID. The problem is that the user is able to select the empty option, and the controler will not be able to fecth the ID. This
2006 Mar 05
3
Trying to connect tables .....
I am trying to ''connect'' two tables AdHour and Ad in the method below. However, the line with the asterisks is causing the following error: "You have a nil object when you didn''t expect it! The error occured while evaluating nil.user_id" I''ve included the model for both AdHour and Ad. Why doesn''t the script like how I am connecting the
2005 Oct 21
8
Wrong number of arguments (1 for 0) on routes.rb
Hi, I''m baffled by this error. I need a simple controller to send e-mails, so first I thought about just creating the controller manually (without using script/generate), since that didn''t seem to work, I created a dummy table in my DB and used the usual procedure to generate scaffold code. Then I modified the controller to have only two methods, send and compose: class
2008 Sep 23
1
Help with "No route matches "/MyTest/" with {:method=>:get}"
I just started working with Ruby. Anyways I can''t seem to figure out how to have this message disappear. I was reading a tutorial and based on it, when I type in http://localhost:3000/MyTest/ it should say whatever I have written down on my my_test_controller.rb file. I first ran: ruby script\generate controller MyTest then I edited the my_test_controller.rb file It currently says:
2006 Jul 06
2
rjs rails to execute?
I have the following: layout: <%= javascript_include_tag :defaults %> [...] <div id="menu"> <div id="myrandom"></div> <%= render :partial => ''menu'' %> </div> menu partial: <%= link_to_remote "Generate Text", :update => ''myrandom'', :url => { :action =>
2006 Jan 18
5
Exception not caught?
Hello all. I have started reading up on exceptions and tried replacing a manual check with one. Given the following code: def results begin @componentlogs = Componentlog.find(:all, :conditions => [ "cl_compname = ?", params[:componentlog][:cl_compname].strip] ) rescue ActiveRecord::RecordNotFound render_text "<p class=''center''>No
2002 Feb 20
2
Unable to join W2K domain
Hello list, I'm trying to join the W2K domain, but without success. After typing the following line /usr/local/samba/bin/smbpasswd -j WORLD -r SRV5N -U adm Password: this message apears: Unable to join domain WORLD The content of smb.conf: [global] netbios name = SRVSX security = domain domain logons = yes workgroup= WORLD password server = SRV5N keep alive = 30 os level = 0 domain master
2006 Jul 31
2
Please HELP: Problem with BUILD command
Greetings, I am unable to successfully BUILD due to a file that apears to be too long. I know it it due to the length of a particular R program because if I remove a line, even a comment line, from the file it then successfully builds. However, if I add the line back in, the build fails. The file is only 14Kb long. Any help or suggestions are greatly appreciated. Thank you for your time.
2006 Apr 11
2
trying to find out how much is on a drive?
I have a Ferdora 2 machine with 2 drives in it one has the OS and the main drive for our Samba server on it and the other is the Mirror drive. What I am trying to find out is how much is on the primary drive. When I use the "du" command I get a number that seems to be off. I have the mirror drive mounted to the primary drive, and it apears as though when I do the "du"
2002 Sep 21
2
Bad links in user profile
Hello, samba. Why some times apears bad links in user profiles. After that profile can not load correctly. After deletion this bad links (usually in NetHood, some times it is files in different folders), all work fine. W2K client report, what this files can not read, but I can read them in default profile mode from home directory. Users can not login with they profile information before I delete
2005 Aug 21
4
SYSLINUX 3.10-pre15
I just picked up 3.10-pre15 and the "PXELINUX corrupts graphic filename referenced from DISPLAY file" bug is zapped. Yipee! Thanks hpa. And Arwin too, if that 'xor esi,esi' was the crux. However, LOCALBOOT -1 and LOCALBOOT 0 don't work the same as they did for me in 3.07. :-( 3.07: LOCALBOOT -1 apears to work as I have a hard disk listed in bios boot order after the