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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T13:11:26+00:00 2026-05-31T13:11:26+00:00

I need to put the input text field and the sumit button on the

  • 0

I need to put the input text field and the sumit button on the same line. I tried a lot things, but nothing worked.

The form:

<%= form_tag("/recherche", :method => "get") do %>
  <%= search_field_tag :recherche, params[:recherche] %>
  <%= submit_tag "Recherche", :name => nil, :id => "submit"%>
<% end %>

Which produces:

<form accept-charset="UTF-8" action="/recherche" method="get"><div style="margin:0;padding:0;display:inline"><input name="utf8" type="hidden" value="&#x2713;" /></div>
  <input id="recherche" name="recherche" type="search" />
  <input id="submit" type="submit" value="Recherche" />
</form>

I have no idea what CSS to use… I tried with float, display, etc.

FYI, the form is wrapped in a <li>.

  • 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-31T13:11:27+00:00Added an answer on May 31, 2026 at 1:11 pm

    In comments, you add that you are using jQuery Mobile. This appears to be the cause of the problem, so the apparent solution would be to stop using it. But if you need it for some reason, check out how it affects your form field widths. How wide is is the input element? You may need to set it smaller, e.g.

    <style>
    #recherche { width: 15em; }
    </style>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have a simple text input field users put in a number. I need
I need to put a custom hover menu from http://www.addthis.com/help/toolbox , but Rails uses
I have a text field that can accept input of any kind. Based on
How to put jquery result in text field. Here is the code: jquery: $(document).ready(function
My script generates a new input field and I want to put a 'span'
How can I write a script that will change an input field's text value,
How might someone fill in an input field with some text using jquery by
I need to put an alpha blended gradient border around an image. My problem
I need to put a control to the right of my MenuStrip. The MenuStrip
I need to put an LDAP contextSource into my Java EE container's JNDI tree

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.