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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T01:24:19+00:00 2026-06-05T01:24:19+00:00

%p %br %span.footer_links = link_to ‘Edit’, edit_link_path(@link) = link_to ‘Edit’, edit_link_path(@link) = button_to ‘Delete’,

  • 0
%p
  %br
  %span.footer_links
    = link_to 'Edit', edit_link_path(@link)
    = link_to 'Edit', edit_link_path(@link)
    = button_to 'Delete', @link, :confirm => 'Are you sure?', :method => :delete
    = button_to 'Delete', @link, :confirm => 'Are you sure?', :method => :delete
    pppppp

Produces “edit” links on the same line but delete buttons on different lines, e.g.

      edit  edit
      delete
      delete

(two of each for emphasis about line breaks)

How can I get all the above on 1 line as in:

edit edit [delete] [delete]

I am doing this becuase I need to change my link_to, :method => :delete to :button_to's

Update: I added, :class => '.btn' to my button_to
with .btn { display: inline; } in my css but it hasn’t helped.

<p>
<br/>
<span class="footer_links">
<a href="/links/354/edit">Edit</a>
 | 
</span>
</p>
<form method="post" action="/links/354" class="button_to">
<div>
<input name="_method" type="hidden" value="delete"/>
<input class=".btn" data-confirm="Are you sure?" type="submit" value="Delete"/>
<input name="authenticity_token" type="hidden" value="MvN6K03y5WcqSZRt4Au3zj+xsKhfZ9EEtkf2M7YCGhk="/>
</div>
</form>
<p/>
  • 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-05T01:24:19+00:00Added an answer on June 5, 2026 at 1:24 am

    Strange, because both the a generated by link_to and the input generated by button_to should be inline elements.

    This is exactly what CSS is for, though: keeping design details out of the HTML. So you could have CSS like this:

    .footer_links a, .footer_links input {
      display: inline;
      padding-right: 1em;
    }
    

    [Useful edit – also from Buck – You can use :form_class and then style the form and the div inside it as inline. ]

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

Sidebar

Related Questions

The span tag that encompasses the text I'm trying to display is of 500px
I have a span with some text, and beneath it should be a textarea
i have a span with class : cash_warn. I want to change the color
I am adding new span elements to a div element (using .append) of fixed
I would like a span to update when a value is entered into a
If I have a span , say: <span id="myspan"> hereismytext </span> How do I
I have WPF Span that is used as a source to a TextBlock. I
I have two span elements that I would like to stay on the same
I have a span with the following style: margin: 5px 0; padding: 2px; cursor:
When a span is nested in a div with a different background there's a

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.