Displaying 20 results from an estimated 1100 matches similar to: "run simple method from Helper on button click"
2015 Oct 27
3
Secure dynamic update failure with internal DNS
Hello,
At one point secure dynamic updates worked. Now I require 'allow
dns updates = nonsecure' for dynamic updates to work. I can't seem to
find any trace of updates being performed in the samba logs or Windows.
I've hit a wall and can't seem to progress. Since I couldn't pull
anything from the logs I decided to run 'nsupdate -g -d -D -L 10'. This
was
2013 Oct 25
6
Migrate postgresql database to uuid
Hi all,
I am using rails 3.1 and ruby 1.9.3,Now i want to use uuid concept in
rails 3 for existing data
so i did like :-
create_table :posts, :id => false do |t|
t.string :uuid, :limit => 36, :primary => true
end
ActiveRecord::Base.class_eval do
# old rails versions
set_primary_key ''uuid''
before_create :generate_uuid
def generate_uuid
self.id =
2006 Aug 14
2
Change Button Text - Ajax
Hi,
I have the following code
<%= button_to_function "Hide", "Element.toggle(''mytext'');"%>
which does toggle the invisiblity of the text just fine, But want I want
via ajax magic, is to also toggle the button text, so it will now
display "Show" when I have toggled the invisiblity of the Div.
Thanks for any help.
John
--
Posted via
2009 Dec 06
3
link_to_function or button_to_function memory usage
I have an full ajax app doing crud operations for contact info for one
section. I was using ajax calls to edit and cancel and also to add a
contact. I am implementing a button_to_function instead of doing an
ajax call to just edit/add/or cancel a contact. I am running into a
memory issue using the button_to_function or link_to_function.
I have this:
<%= link_to_function ''Edit
2010 Oct 20
2
How do i use button_to_function
Hii all ,
I am trying to create a button that, when clicked on, calls a
method in a controller . I am thinking that button_to_function is good
to use for that i made htnl viwe like
<h1>File Upload</h1>
<p><label for="upload_file">Select File</label> :
<%= file_field ''upload'', ''datafile'' %></p>
2010 Mar 22
7
How to reference a select_tag within a form
Hi All,
Inside my app\views\expenses\new.html.erb file, I had the code:
<% form_for(@expense) do |f| %>
[snip]
<p>
<%= f.label :vendor %><br />
<%= f.text_field :vendor %>
<br />
<div id="vendor_droplist>
<%= select_tag "test",
options_for_select(@current_vendors.collect { |v|
v.nickname }),
{:multiple
2006 Jul 21
10
Using an image button for "link_to_remote"
All,
I want to do an AJAX request using a custom image button. I currently
have this as a standard button action using "button_to".
What I need is the button equivalent of "link_to_remote". Is there a
helper that I can use, or do I need to build it by hand?
I see button_to_function(), but that sets me up to call a Javascript
function, not post to a Rails action.
Or can
2007 Dec 04
2
button_to_function question
Hey everybody,
I am trying to create a button that, when clicked on, calls a method
in a controller then changes the image on the button without a page
load. I was thinking that button_to_function might be a good
contender for this but I don''t yet know how to make it talk to a
controller, and on success change the image of the button. Can anyone
help me out with this problem?
Thanks,
2020 Jul 02
0
samab-4.10 nsupdate
This is all the diagnostic information I can think of at the moment:
[root at smb4-1 ~ (master)]# klist
Credentials cache: FILE:/tmp/krb5cc_0
Principal: administrator at BROCKLEY.HARTE-LYNE.CA
Issued Expires Principal
Jul 2 10:35:11 2020 Jul 2 20:35:11 2020
krbtgt/BROCKLEY.HARTE-LYNE.CA at BROCKLEY.HARTE-LYNE.CA
[root at smb4-1 ~ (master)]# grep nsup
2012 Sep 23
6
Missing template projects/index, application/index ?
Getting this issue...even though I have my views there in both the projects
and application. Also getting a routes issue "No route matches [GET]
"/projects" when going to projects when I have root :to => "projects#index"
defined in my routes file.
Any idea?
1) Creating Projects can create a project
Failure/Error: visit ''/''
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
2011 Jun 11
7
"Stack level too" deep with @controller.hi
Hi again, sorry for many questions. In mi HomeController, I have the
"hi" method, in this method I use an "if" for show a different message
for a registered user or a guest. When I call in "home/index" my
method "hi", show me this error message:
"Stack level too deep"
class HomeController < ApplicationController
def hi
if (current_user)
2006 Jul 16
7
form_helpers ?
Just a quick silly question , are form_helpers actually helper.rb files ?
Stuart
2009 Apr 24
2
passing a value to a js function via button_to_function
I''ve got a table of what I call resources, want to show in a jQuery
dialog a particular record when user clicks button in a row.
in the table I''m doing:
<td><%=button_to_function ''Show'',''showresource1()'',:class =>"ui-button
ui-state-default ui-corner-all", :id => resource.id %></td>
js:
<script
2006 Jul 13
5
Does Javascript let you default input params like Ruby does?
Can you have a Javascript function with a param that''s defaulted if it
isn''t present?
function X(a, b = false, c = ''dog'') {
}
X(5) calls X with a=5, b=false, c=''dog''
X(4, true) calls X with a=4, b=true, c=''dog''
X(3, true, ''cat'') calls X with a=3, b=true, c=''cat''
?
--
Posted via
2009 Jul 08
1
Final follow up patch to add warning for NTP...
Now, rather than displaying yet another warning, the NTP configuration
just requires that the user select a NIC to configure first. That act
alone provides the single warning to the user that they'll be changing
their network configuration.
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
2012 Apr 19
2
method value passing in rails
in my ruby on rails application, i have one controller
class HomeController < ApplicationController
def home
puts "name.....#{@name}"
end
def branch
*//HERE HAVE TO GET THE ABOVE FUNCTION VALUE @name*
end
end
What am trying to do, i have to get the @name value in method branch. i
could show the value in function home, but i didn''t get that in
2011 Feb 14
1
Curiosity in my production.log: */*
In my production.log, I usually see lines like this:
Processing by HomeController#index as HTML
But sometimes I see the line like this:
Processing by HomeController#index as */*
At first I thought perhaps those calls were made by a bot, but after
looking at it closer it looks as those they are generated by normal
users. I have no idea, first, how that line could have been generated,
and
2010 Jun 21
4
Failing Routes in deployment
I have an app that has the following in the routes file:
namespace "admin" do
# ADMINISTRATIVE ROUTES ONLY
root :to => ''home#index''
resources :comments do
member do
get :approve
get :reject
end
end
resources :users do
member do
get :block
get :unblock
end
end
end
When browing to