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

  • Home
  • SEARCH
  • 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 6005071
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T01:21:05+00:00 2026-05-23T01:21:05+00:00

I am building an admin section for an app I’m working that lists businesses.

  • 0

I am building an admin section for an app I’m working that lists businesses. Admins can then go in and submit an email address and activate the business. So I am using a form_tag within a block like so:

<% for business in @businesses %>   
<tr>
    <td align="center" class="border-table"><%= business.id %></td>
    <td align="center" class="border-table"><%= business.name %></td>
    <td align="center" class="border-table"><%= business.address %></td>
    <td align="center" class="border-table"><%= business.phone %></td>
    <% @user = User.new %>
    <%= form_tag "/businesses/activate?business_id=#{business.id}", :remote => true, :method => :put do %>
        <td align="center" class="border-table" id="<%= business.id %>_email"><%= text_field_tag "email", nil, :placeholder => "email" %></td>
        <td align="center" class="border-table" id="<%= business.id %>_activate"><%= submit_tag "Activate" %></td>
    <% end %>
  </tr>
<% end %>

So on a given admin page there are 25 of these forms, one for each row in the table.

The problem is, for whatever reason, the “email” param is not getting posted, just the business_id (from the path).

Is there something I am doing wrong? Are you not supposed to generate multiple similar forms using a block?

Any advice would be much appreciated.

Thanks!

  • 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-05-23T01:21:06+00:00Added an answer on May 23, 2026 at 1:21 am

    i figured it out. it seems most browsers won’t pass the params of a form unless it’s inside the <td> like so:

    <td align="center" class="border-table" id="<%= rep.id %>_email">
      <%= form_tag activate_rep_path(rep.id), :remote => true do %>
      <%= text_field_tag "email", nil, :placeholder => "email", :index => rep.id %></td>
    <td align="center" class="border-table" id="<%= rep.id %>_activate">
      <%= submit_tag "Activate" %>
      <% end %>
    </td>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm building a (CakePHP) website with an admin section that allows rich text editing
In the admin section of a website i am building i would like to
When building an iPhone app that uses the Core Plot framework, I am seeing
Im building a web application which is a process management app. Several different employee
When building static libraries with VS2005 I keep getting linker warnings that VC80.pdb cant
I am building an admin panel. and I want to block certain IP ranges.
I'm currently building a job-board website with CodeIgniter 2.0 that is very user content
Building on How Do You Express Binary Literals in Python , I was thinking
Building a client-side swing application what should be notified on a bus (application-wide message
Building the same project (without any changes) produces binary different exe-files: some small regions

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.