similar to: using :post => ''true'' still makes a GET request

Displaying 20 results from an estimated 10000 matches similar to: "using :post => ''true'' still makes a GET request"

2006 May 09
3
send a POST off a link, not a button.
Hi, Got a question about how the book suggests sending POST requests using a form whenever one intents to change some database state. So I converted a bunch of links to forms which ended up creating buttons. I was wondering if there was a way to keep them links rather than buttons but still use POST in a form? thanks. -------------- next part -------------- An HTML attachment was scrubbed...
2006 Jan 22
6
Destructive behavior with link_to, button_to, :post=>true
Hello- I would like to know what the suggested practice is for having multiple submit buttons on a relatively complicated input page. Let''s use the example of a Contact. There is lots of info there, including name, address, phone number. There is also a list of "contact associations" which can be modified on the same page. Ideally, the user could have one
2006 May 23
4
''key not found'' problem with saving model object.
Hello, I have the following structure: model foo has_many :bars:, :dependent => true end model bar belongs_to :foo end In my action, when i try to save foo: def save begin f = foo.new f.a = 5 begin b = bar.new b.a = 10 f.bars << b rescue Exception => exc ... end f.save! <-- This does not happen
2007 Feb 27
1
link_to :post true Newbie question
Hi All, I am attempting to use a link_to helper to perform a form post using the following construct: <%= link_to ''Save'', {:action =>''create''}, :post => true %> What I find is the parameters passed to the webserver are empty. My model validation stuff triggers indicating the fields in question are empty too. This is to create a new DB entry so no
2006 May 16
4
question about strftime when called from partial.
Hi, I''m calling a helper I''ve written - format_time() that is called from my views with a given time that was selected from my database and was returned to the view via an instance variable. When I call format_time from a partial, I see that I get some kind of String error and the partial won''t render. Basically, the object being passed in to format_time is already a
2006 May 08
4
link_to - Going Back without knowing the action name.
Hi, I have a bunch of link_to''s in my code that are simple Back buttons that should basically just go to the previous request. Is there a way of doing this without specifying the action to execute? The problem is, sometimes I may render the same view through separate actions so I wouldn''t know which action to go back to. Thanks. -------------- next part -------------- An HTML
2006 May 31
1
embedding link_to''s as part of rendered text.
Hi, I''d like to be able to do a database query, fetch some text, and add an ''Accept Request'' and ''Deny Request'' within the text. Both of these would be links so if the user were to click on them, they would essentially send POST requests back to the server. Since this is dynamic, I wanted to know the safest/best approach in embedding these links
2006 May 10
2
session[:return_to] for going back.
Hi, Is session[:return_to] something Rails maintains to quickly go back to the previous uri without having to keep track of the action name? Or, do we have to actually set it in our actions? Thanks. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060510/7e36a528/attachment.html
2006 May 30
3
expected, got Fixnum problem.
Hi, I was wondering if anybody knew what ''<some type> expected, got Fixnum'' means? My code looks like the following: begin anevent = Event.new anevent.title = params["event"]["title"] anevent = session[:user_id] com = Community.find(params[:id]) com.events << anevent rescue Exception => exc ... end But I get an
2007 Jan 21
1
noob with :method => :post vs. :post => 'true' dilemma
Okay, I''ve worked through the tutorial in 2nd ed. Agile Dev book. And I think I understand the methods concerning user management; however, when I use :method => :post in my app, I get a link of the following variety: <li><a href="/login/delete_user/2" method="post" onclick="return confirm(''Really delete
2006 Jun 06
4
Checking if a directory is empty using File
Hi, I have one minor issue. I''m trying to check whether a directory is empty given some path to the directory. My code does the following: if(File.directory?(dirpath)) # dirpath = public/images/1 if(File.zero?(dirpath)) FileUtils.rm_rf(dirpath) end end The problem is, while testing this, if I put a file in the directory and run the above code, it still ends up deleting the
2006 May 10
2
getting absolute paths on files on filesystem.
Hi, I''d like to be able to store the absolute path for a file so that I could use <img src = "...." > and give it the path to the file I''d like to display. I was wondering if there is an easy way to do this and whether there are any issues with this on Windows. thanks in advance. -------------- next part -------------- An HTML attachment was scrubbed... URL:
2006 May 10
2
accessing uploaded file on filesystem question.
Hi, I''m able to upload files onto my webserver filesystem but I had a question regarding how I''d go about accessing them using the <img src="..." > tag. If my files, i.e pictures, are being uploaded to public/images/<dir>/filename.jpg, then should I store the entire path, or just the picture name in my database table? I would imagine storing just the
2006 Oct 06
0
link_to with :post => true causes "link hop" on submit
I have a link_to function that I''m calling with :post => true. When I click it, the link (which is in a table cell) moves up a bit and pushes the next table row down just a bit, like it''s hopping. My guess is that in the generated Javascript (by link_to), the addition of the form to the DOM is causing the link itself to move. Anyone seen this before, and if so, know a
2006 Feb 14
0
help: link_to with :post => true
I''m having trouble getting anything in the params hash when I do: <%= form_tag(:action => ''edit'') %> <table border="0" id="detailtable"> <tr> <td>* Email:</td><td><%= text_field_tag(''member[email]'') %></td> </tr> <tr> <td colspan="2" /> </tr>
2016 Jun 23
2
Samba pid in uninterruptible state
Greetings, I recently upgraded Samba on an Ubuntu 14.04.2 server from version 4.1.9 to 4.2.3. Upon rebooting Samba process goes into a running state then after a short time it will go into an uninterruptible state. If I check the log.samba, it appears that it is attempting to start, then hangs at the following: [2016/06/23 15:16:00.329503, 3] ../source4/param/share.c:124(share_register)
2006 May 23
11
adding layouts within layouts
Hi, I want to be able to have several layouts within each other so that I don''t have to keep repeating the layout code for one, in another. An example would be having a layout for the title of your web page and then having an embedded layout for the body portion in which the HTML for whatever view gets displayed. Is this possible? Thanks. -------------- next part -------------- An
2006 May 18
6
NOOB: Second post, please help...
Folks, I am linking from page A to page B, and back again. When I go from A -> B, the B_controller.rb runs fine, and the page renders properly. But, when I go from B -> A, the A_controller.rb doesn''t run again, so the array (@A) is nil (which causes a problem). Should the controller run each time the page is accessed? Any ideas? Marcus Marcus Blankenship Technology Services -
2016 Jul 28
3
DomainDnsZones inbound replication issue
Greetings, I am having a problem with one of my DCs (DC3) replicating DomainDnsZones. On DC3 replication is successful on both Inbound and Outbound with both of my other DCs. On both of my other DCs (DC1 & DC2) I only get a failure with Inbound replication for DomainDnsZones from DC3 with a result 8442 (WERR_DS_DRA_INTERNAL_ERROR). If I try to force replication to DC3 from DC1 using
2006 Jul 03
2
Still struggling with data flow ...
Hello, The following view: <%= start_form_tag %> Enter term to find <p> <%= text_field_tag :name, params[:name] %> </p> <%= link_to "Find", { :action => ''find_term''} %> <%= end_form_tag %> does not appear to pass back the value of :name to the action: def find_term term =