Displaying 20 results from an estimated 8000 matches similar to: "how to make confirm boxes conditional?"
2008 Jun 15
11
[PATCH] helper to create fb css stylized table
I attached a rails helper implementation of the fb_table described here:
http://wiki.developers.facebook.com/index.php/Facebook_Styles
I included testing and comments. I hope you find it useful.
Curiously, it''s really a small extension of FBML.
Richard
-------------- next part --------------
Index: test/rails_integration_test.rb
2007 Sep 04
2
How can i add a confirmation dialog to a submit_tag?
When i use button_to or link_to, i can easily request a confirmation
dialog with (for example)
<%= button_to "Delete this story",
{ :controller => "story", :action => "delete", :id => @story.id },
:confirm => "Delete story: are you sure?" %>
I also want to do this for the submit buttons on my forms, which are
2009 Aug 18
5
Increment counter on download
i am offering my site visitors a download of zip file. when someone
downloads it, i want to increment a counter and update db. how do i do
that?
--
Posted via http://www.ruby-forum.com/.
2008 Apr 30
5
Quick Submit Button Question...
Hello,
Can I pass a variable from a submit button only? I have a form that the
user fills out and I need two different submit buttons - one for ''sync''
and one for ''full push''. I was thinking I could add some sort of param
to the button, but it''s not working... is there a way to do this? I have
this:
<%= submit_tag ''push to
2006 Aug 18
4
Button on view
Hi,
I have a page containing 3 views (2 are partials). One of the partials
needs to have a button that will clear a table called "messages" in the
database.
I can put a button like this "<%= button_to "Clear Messages", :action =>
''clear_messages'' %>" and have the controller do "Message.delete_all".
But the problem is that the
2007 May 19
4
button_to_function with image?
Hi:
does button_to_function allow the use of an image? I tried it in place
of the text with "image_tag" and it doesn''t work. Maybe some form of
button_to?
Any direction you can give would be great!
Mike
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
2008 Apr 01
1
Navigation Problems
Hi,
I am having problems with my page. I have a banner and navigation bar in
controller_name.rhtml in app/views/layout. Can someone please help?
Thanks
In the navigation bar, I have the following links:
Category1
Sub-Category1
Sub-Category2
Sub-Category3
Sub-Category4
Sub-Category5
Sub-Category6
In the main content, I have the following links:
Sub-Category1 edit delete
2006 Jul 24
2
:disable_with for button_to ???
With form_tag submit buttons I use the " :disable_with => ''button label while processing'' " option so that visitors with slow connections aren''t able to submit forms twice.
How do I do the same thing with button_to?
I''ve got several pages where there are multiple forms on the page being updated with Ajax so I can''t wrap the whole
2010 Oct 31
4
Newbie - Rails 3 authentication question (Devise)
Hello!
I''m working on my first Rails app and I have a question regarding
authentication. I already have authentication for signing up, logging
in, logging out, etc. What I need is an account email activation
function and a reset password (forgot password) function. I have read
a little bit about Devise and watched the Railscast episodes on it, it
seems nice, but is it possible to add
2006 Jan 08
4
scaffold uses link_to for destroy
Hi,
I wonder why scaffolding uses a link_to tag for the destroy links.
Seems like these should be POST requests with button_to. The Rails
book dedicates pages 335-337 to this very issue.
Peter
2008 Jun 19
2
Non editable file_field
Hi,
I need to upload files in my application
I am using following code
<tr>
<td width="125">Upload Document:</td><td width="400"><%=
form.file_field("filename") %></td>
</tr>
But I want that the file field that gets displayed in my browser should
not be editable.
i.e user should be able to select the file through the
2006 Mar 25
5
button_to with image?
I''m trying to use button_to and have it use an image in place of the
submit button. I had figured it would work the same as link_to like so:
button_to(image_tag("editicon", :size => "16x16", :border => 0), :action
=> ''edit'', :id => person.id)
but this instead displays the image code as the button name. Surely
there is a simple way to
2006 May 25
5
CSS Effects? (javascript?)
Is there a way to assign a CSS style to an element I am not currently
interacting with? For instance, if I have two TD elements of a table. I
click on one of them, and I want to have a style change in the other
element. Is this possible?
I''m guessing script.aculo.us might be able to help me.... but
considering how nothing on their site is loading for me right now I have
no way of
2006 Jan 28
7
cool components in the form
Is there a easy way to add components like:
http://www.dynarch.com/projects/calendar/
http://tinymce.moxiecode.com/example_full.php?example=true
in ruby forms, by plugins or whatever?
Thank you
Rodrigo Dom?nguez
Iplan Networs
www.iplan.com.ar <http://www.iplan.com.ar/> ? rdominguez@iplan.com.ar
www.rorra.com.ar <http://www.rorra.com.ar/> ? rorra@rorra.com.ar
--------------
2007 Mar 23
11
Is there such a thing as button_to_remote?
I''ve changed my destructive link_to statements in favor of button_to.
But what if I want to make an .rjs call with that button?
Seems like we need something equivalent to link_to_remote, so that the
button can make an ajax request instead submitting the form.
Or am I missing the point entirely?
Jeff
--~--~---------~--~----~------------~-------~--~----~
You received this message
2007 Feb 24
2
RESTful PUT and button_to
I''m working on a RESTful app, and I''ve hit a snag. Here''s a
simplified example of the problem. (Excuse me if this example code
isn''t strictly correct; I''m typing from memory.)
Suppose I have a table which models a simple counter. It has a single
column, "count":
class CreateCounters < ActiveRecord::Migration
def self.up
2011 Oct 21
20
How to transform my html form into a rails 3 form
Hi,
I have the following code working in a rails 3 view, but it is
unfortunately not pure rails code!
<% @filter1 = "tr.show1,tr.show2" %>
<% @filter2 = "tr.show1" %>
<% @filter3 = "tr.show2" %>
<form>
<p>
<input type="checkbox" value=<%=@filter1%> onclick="$
(this).is('':checked'')
2007 Jan 16
2
RESTful routes and Mime::Type
Hi all
I''m using RESTful routes combined with the to_csv plugin and would
like to know if there''s a nicer way of generating a link to fetch the
CSV file than just making a hard link. This is what I use for the
moment (and it works btw):
<%= link_to("Export as CSV","/companies.csv") -%>
I would expect the link helper to have something like
2006 Mar 02
4
Instance variables in Javascript param
How can I make this work ?
<a href="#" onclick="new Effect.Fade(@div_id)"></a>
@div_id is an instance variable ?
TIA
--
Posted via http://www.ruby-forum.com/.
2009 Dec 18
2
Undefined Method error - help request
Good morning All -
I am working on a time tracking application as a learning excercise
and have run into an error neither I nor Google can remedy.
When loading my view, I get an error: ''undefined method
''true_class_path'' for #<ActionView::Base:.........
Context:
I have controllers for Project, Worktrack and ''Workbench'', among
others. Workbench is