Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7888229
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T05:46:48+00:00 2026-06-03T05:46:48+00:00

why when im trying to send this three params(recipients_emails) I get error: ArgumentError in

  • 0

why when im trying to send this three params(recipients_emails) I get error:

ArgumentError in FreeRegistrationCouponsController#send

wrong number of arguments (2 for 0) Rails.root:
/Users/regedarek/code/wifiname

Application Trace | Framework Trace | Full Trace
app/controllers/free_registration_coupons_controller.rbin `send’

What Im doing wrong?

<div class="span6">
  <b>Give three of your friends a free registration</b>
  <%= form_tag :controller => 'free_registration_coupons', :action => "send" do %>
    <%= label_tag :recipient_email_1 %>
    <%= text_field_tag :recipient_email_1 %>
    <%= label_tag :recipient_email_2 %>
    <%= text_field_tag :recipient_email_2 %>
    <%= label_tag :recipient_email_3 %>
    <%= text_field_tag :recipient_email_3 %>
    <%= submit_tag %>
  <% end %>
</div>

class FreeRegistrationCouponsController < ApplicationController
  def send
    @sender_id = current_user.id

    binding.pry
    redirect_to root_path
  end
end

resources :free_registration_coupons do
  collection do
    get 'send'
    post 'send'
  end
end
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T05:46:50+00:00Added an answer on June 3, 2026 at 5:46 am

    Don’t call your action send – you’re overwriting a core ruby method. Rails is trying to call this core ruby method, but ends up calling your method instead, which has a different signature.

    Rails should probably be using __send__ so that you are free to use send for your own purposes, but there’s not much you can do about that right now.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to send an array of this struct to a DBus Server:
I am trying to send user to previous page history.go(-1). This works fine in
I am trying to send a soap message to an external system, this system
I am trying to send data from an activity to service via intents. This
I'm trying to send an XMLHttpRequest object to my Rails server but the headers
I'm trying to send a GET request to a App Engine server from a
I am trying to get a Android device to send some information to a
I’m at my wit’s end trying to figure this out. I'm experienced in WPF,
Trying to send some email in my C# app. I am behind a proxy
Trying to send a complex type between two systems that have the same code

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.