Displaying 20 results from an estimated 1400 matches similar to: "remote_form_for, paths, and partials"
2009 Mar 10
5
onsubmit for remote_form_for not working properly
I want to use onsubmit for a form validation using javascript on
remote_form_for
for this i am doing something like this
<% remote_form_for :timesheet, @timesheet, :url =>{:action =>
''report_user''}, :html => {:onsubmit=>"return ValidateDate();" } do |f|
%>
// Form elements here
<% end %>
but it not works well. if condition return false
2007 Jul 12
1
remote_form_for behavior on javascript submit();
Hey all,
Tried this on the IRC channel but after an hour i figured nobody that
was on knew, so i''ll try it here. I have a rhtml page with:
<% remote_form_for(:performance_goal, :url =>
user_performance_goal_path(@user.account, @user,
@performance_goal), :html => {:id => ''sidebar_form'', :method => :put})
do |f| %>
<%= f.text_area :impact, :size
2008 Mar 04
3
remote_form_for does not work with method = :get
It seems that remote_form_for does not work with method = :get since
it does not change the prototype call. Is this a bug?
--~--~---------~--~----~------------~-------~--~----~
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 unsubscribe
2009 Mar 15
1
remote_form_for ajax validation
Hi,
I have been reading a lot about this, but I do not manage to do a nice
validation. I already managed to save data to the database, to
validate a field, to display a "Everything went well" message. I can
also display an error message, but the view does not end up properly.
This is the form:
<% remote_form_for(product) do |f| %>
<%= f.error_messages %>
<p>
2007 Aug 01
1
multipart remote_form_for
I''m trying to figure out how to create an AJAXified form with
remote_form_for that can submit a file upload, to no avail. Any pointers
for me?
- donald
--~--~---------~--~----~------------~-------~--~----~
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
2008 Oct 24
4
Railscast 75, Observe_field and Shopping Cart
Hi all,
I have the shopping cart page where a user can add items dynamically
through ajax as explained in Railscast episode 75. I am using
observe_field to observe the ''quantity'' and ''cost'' fields to update
the total field for each item.
This does not work however, for records that are added through the
Ajax. How can i name the fields and observe them as i have
2006 Apr 05
2
RJS and remote forms
I''ve run into what I think is a browser bug related to using
remote_forms pushed in an RJS update.
In my controller, I have an action that creates a new model and returns
a form for one of its children:
def create_party
party = Party.create
render :update do |page|
page.insert_html :top, ''party-list'', :partial => ''party_header'',
2008 Jan 03
0
remote_form_for with auto_complete_field
Hi friends
I have problem with auto_complete_field.
I have used auto_complete_field with in the remote_form_for.
But when we enter the text in auto_complete_field two actions are
calling
1. auto_complete_field action
2. remote_form_for action
I need to restrict the form action when we enter text on
auto_complete_field
Could u give any ideas?
<div
2007 Nov 08
0
Models for external REST services
Hello, I''m new to rails so as an exercise I''m porting (php to rails)
a very simple landing page that talks with a third party REST service
where I just need to do a couple of calls to register a user and show
the status of the whole process. I felt this would be dead simple to
do in Rails (I''m still learning) but I''m having a hard time getting it
working.
My
2007 Oct 15
6
Form with two buttons
Hi,
I need to make a form with two buttons. But I do wrong. And why not can
be.
form:
-------------------------------
<%= form_tag :controller => ''establishment_contents'', :action =>
''llamada'', :opMenu => opcionMenu %>
[...]
<%= image_submit_tag ("../images/incluir.gif", :op=>"addImage") %>
[...]
<%=
2007 Jun 03
3
remote_form_for issue
Hi everybody,
I''m trying to change my current forms in my app to remote_forms. It was
my understanding that remote_form_for and form_for work in the same way,
so I just wanted to change the methods. My code looks like:
<% form_remote_for :post, :url => posts_url do |f| %>
<%= render :partial => ''form_posts'', :locals => {:f => f} %>
<%=
2009 Jan 18
2
InvalidAuthenticityToken error with remote_form_for
Hi All -
I have a form_for that I''m trying to convert to remote_form_for, and I
keep get this error:
ActionController::InvalidAuthenticityToken
(ActionController::InvalidAuthenticityToken):
/usr/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/request_forgery_protection.rb:86:in
`verify_authenticity_token''
2008 Jan 11
1
Remote form for, Form.serialize and parameter arrays
Whenever I use regular form for and have an attribute list containing
an array all goes fine and it results in parameters like:
{"some_attributes"=>[{"title"=>"first_title", "text" => "text1"},
{"title"=>"second_title", "text"=>"text2"}]}
However whenever I submit the same form with
2010 Jul 27
7
trouble with remote_form_for & html_update
I have a form that accepts comments and adds them to a list without
refreshing the page.
This is the html:
<div id=''aremark''>
<%= render :partial => ''comment'' %>
</div>
<% remote_form_for :comment, :url=>story_comments_path(@story), :html
=> { :id => ''comment'' } do |form| %>
<h5><label
2013 Oct 30
3
Use of FCKEDITOR as normal text area
Hi all
I am trying to use Fckeditor as text area to send mails.here is my code
<% remote_form_for :send_sms,
:before => "Element.show(''loader'')",
:success => "Element.hide(''loader'')" do |sms| %>
<div id="news_content_text_field_bg">
<%= fckeditor_textarea :send_sms, :message,:lang =>
2008 Mar 14
8
Facebooker updates
I just went through and cleaned out most of the bugs and patches. I
also added a facebooker.js file that implements enough of prototype to
do $() and link_to_remote with :update and remote_form_for with :update
Let me know if you run into any issues with it.
Mike
--
Mike Mangino
http://www.elevatedrails.com
2007 Mar 06
1
link_to, image_submit_tag, "changes only with POST" and "usability without Javascript" question
Hello,
I want to have the following features in my rails application:
1. the program should have AJAX if Javascript available
2. I want to protect my application described in
http://www.w3.org/2001/tag/doc/whenToUseGet.html - means GET should be
safe
3. if Javascript is disabled the application should work too (without
AJAX)
If I use "GET should be safe" option (verify) and link_to
2009 Nov 26
9
ActionView::TemplateError (can't convert ActiveRecord::Error into String)
I cannot work out why this error is appearing.
ActionView::TemplateError (can''t convert ActiveRecord::Error into
String) on line #3 of app/views/button/_show_enquiry.html.erb:
1: <h1>Send us a message</h1>
2: <% remote_form_for :enquiry, :url => {:action => ''send_mail''} do |
f| %>
3: <%= error_messages_for ''enquiry'',
2006 Jun 16
2
image_select_tag with name and value
What have I missed
I have a .rhtml with the sandard form parameters
<%= image_submit_tag("excel.gif", :alt => "Download List to Excel",
:border => 0, :name => ''render_action'', :value => ''excel'' ) %>
Which genenerates I believe a valid html fragment for a submit button.
<input alt="Download List to Excel"
2009 Oct 07
1
Empty validation error messages?
Hello,
I''m have a form and the error messages are not being displayed properly
I got a remote_form_for and am trying to show errors like I always do:
<%= error_messages_for @user%>
but the output is:
4 errors prohibited this user from being saved
There were problems with the following fields:
* {{attribute}} {{message}}
* {{attribute}} {{message}}
* {{attribute}}