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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T16:55:09+00:00 2026-05-31T16:55:09+00:00

In the code given below, I need to position the userid box in the

  • 0

In the code given below, I need to position the userid box in the center. I could not do this after many attempts. Sorry for being so naive.
My HTML and css file are as follows:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head>
<link rel="stylesheet" type="text/css" href="styledel.css" />
</head>

<body>
<input type="text" name="userid" id="userid">  <!-- this need to go in the center -->
<br/><br/><br/>


<form action="http://localhost" method="post" name="form"">
        <label for="name">Name</label>
                <input type="text" id="name" name="name" disabled="disabled" />
                <br></br>

                <label for="email">E - mail</label>
                <input type="text" name="email">
                <br></br>

                <label for="password">Select Password</label>                
                <input type="password" name="password" >
                <br></br>

                <label for="password2">Retype Password</label>
                <input type="password" name="password2" >
                <br></br>
    <input type="submit" value="Submit" />
</form>

</body>
</html>

My css file is as follows:
styledel.css

* {
    margin: 0;
    padding: 0;
}

body {
    font-family: Helvetica, sans-serif;
    }

#page-wrap {    /*showing white background*/ 
    width: 600px;
    background: white;
    padding: 20px 50px 20px 50px;
    margin: 20px auto;
    min-height: 500px;
    height: auto !important;
    height: 500px;
}

form, br {
    clear: left;
    margin: 0;
    padding: 0;
}

input.form_element {
    width: 221px;
    background: transparent url('bg.jpg') no-repeat;
    color : #747862;
    height:20px;
    border:0;
    padding:4px 8px;
    margin-bottom:0px;
}

.checkun{
    width: 150px;
    background: transparent url('bg.jpg') no-repeat;
    color : #747862;
    height:20px;
    border:1px solid blue;
    padding:4px 10px;
    margin-bottom:0px;
    position: right;
}

label, input {
    width: 160px;
    float: left;
    font: 11px bold Tahoma, Arial, sans-serif;
    margin: 1px;
    padding: 2px;
}

label {
    font: 14px bold Tahoma, Arial, sans-serif;
    background: #eeeeee;
}

input {
    width: 200px;
    padding: 2px;
    border: 1px solid #aaa;
}

Thanks in advance.

  • 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-31T16:55:10+00:00Added an answer on May 31, 2026 at 4:55 pm

    You can try by adding a the input in a div and setting the margin as auto for that div

    #user-id-div
    {
    width:200px;
    margin:auto;    
    }
    

    Example:
    http://jsfiddle.net/R3quk/4/

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

Sidebar

Related Questions

In the code given below, I am trying to modify it in such a
Hello friends i am running code given below which contains the setLogTimeEntery function and
Technology Used:- Asp.Net 2.0 Code:- See Below Description:- hello code given below is working
How to know the Id of item I clicked? my code is given below:
I tried the following code in LINQPad and got the results given below: List<string>
Given the below setup and code snippets, what reasons can you come up with
Given the code below, how would you create/implement SR.h so that it produces the
Given the code below ... Net::HTTP.start('localhost', 4000) do |http| # # usual stuff omitted
Given the code below, how do I compare a List of objects's values with
Can we move default file to another filegroup. sample code is given below Sample

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.