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 8141011
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T12:21:14+00:00 2026-06-06T12:21:14+00:00

I have the follwoing form in my view : I have an instance variable

  • 0

I have the follwoing form in my view :

I have an instance variable @selected_folder somewhere above in this view

<%= form_for :workflow_selection, :remote => true, :method => "get", :url => {:action => "final_submission"} do |f| %>  

            <p> Check the workflows needed and then click on the button with folder name</p>

            <% @workflow_map[@selected_folder].each do |i| %> 

            <p><%= f.check_box(i)%> <%= f.label(i, i)%><br /><p>
            <% end %>

            <br />
            <p><%= f.submit @selected_folder%></p> 
            <% end %>

I want to label the submit button as just ‘submit' and should still be able to pass the @selected_folder instance variable to the final_submission action mentioned in the form_for tag

I tried various option like

<%= form_for :workflow_selection, :remote => true, :method => "get", :selected_folder => @selected_folder
    :url => {:action => "final_submission"} do |f| %>  

i tried to create a select drop down and hide it from view but still trying it to pass once the submit button is clicked.

and some more options..

None of them worked

Please help.

  • 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-06T12:21:16+00:00Added an answer on June 6, 2026 at 12:21 pm

    If you want to pass @selected_folder along in the form submission, you can add a hidden_field_tag.

    As per Rails documentation:

    hidden_field_tag(name, value = nil, options = {})

    So in your case

    <%= hidden_field_tag 'selected_folder', @selected_folder %>

    in the workflow_selection, selected_folder will be present in the form hash.

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

Sidebar

Related Questions

I have the following form <form name=myForm id=myForm method=post enctype=multipart/form-data action=script.php> and this jQuery
I have the following form on an .NET MVC View: <form method=post enctype=multipart/form-data action=/Video/UploadDocument>
Hi, I have the following in my view : <form id=list_ad method=get class=adListFilter action=<%=Url.Action(List,
I have done the following form <% form_for @anexo, :url => {:action => create},
I have a simple form on an ASP.NET MVC site that I'm building. This
I have the following form in a partial view @model PartDetail @using (Ajax.BeginForm(Create, Part,
Hi I have the following view that gets the values for the form fields
I have the following form in my /app/views/password_resets/new.html.erb view <% form_tag password_resets_path do %>
I have the following jQuery js to insert a form in my view (in
I have the following form, which I have reduced as much as I can,

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.