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

The Archive Base Latest Questions

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

I have to send id in my controller like this: <%=link_to(@active,{:controller => ’emppedes’, :action=>

  • 0

I have to send id in my controller like this:

<%=link_to(@active,{:controller => 'emppedes', :action=> 'index', :id => @id})%>

but using href instead of link_to. If I do this with href:

<a href="/emppedes">

the id is not sent.

<a href="/ emppedes :id => @id">

does not work. How can I send id through href?

  • 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-14T17:38:23+00:00Added an answer on June 14, 2026 at 5:38 pm

    Why can’t you use the link_to helper? Anyway, you probably want:

    <a href="/emppedes?id=<%=@id%>">
    

    But i strongly recommend against using raw tags for links inside your app. I’m sure you can achieve everything with the link_to helper, too. Please give an example why you think you can’t use it.


    (In reply to your comment) I would do it this way:

    <%= content_tag :li, :class => ( 'active' if @active == "personaldetails" ) do %>
      <%= link_to '/emppedes', :id => @id do %>
        <i class="icon-chevron-right"></i>
        Personal Details
      <% end %>
    <% end %>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a link_to like this: <%= link_to Nuevo Contrato, {:controller => hotels, :action
I have something like: <h:commandButton> <h:ajax event=click listener=#{controller.onLog} onchange=onLogProcess /> .... </h:commandButton> I send
I have send an email using php mailer class. mail was sending successfully but
Lets say i have a Controller like this one : @RequestMapping(method=RequestMethod.GET, value=/error) public void
I have an ActionMailer controller that's supposed to send this file: /user_mailer/welcome_email.text.erb This is
redirect_to :controller=>'groups',:action=>'invite' but I got error because redirect_to send GET method I want to
This seems like it should be straight-forward, but I'm stumped. I have a link
I have a basic controller, just like this: class BookingController { def periodCheck(){ }
I'm trying to send data to the Controller from the View. I have a
I am using Lotus Notes Java API for my application. I have send one

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.