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

  • Home
  • SEARCH
  • 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 6476965
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T06:53:24+00:00 2026-05-25T06:53:24+00:00

<div style=width:500px;> <p>To create not a block, but an inline code span,use backticks:Press the

  • 0
<div style="width:500px;">
    <p>To create not a block, but an inline code span,use backticks:Press the `<Tab>` key, then type a `$`.If you want to have a preformatted block within a list, indent by eight spaces: </p>
    <table>
<thead>
    <tr><th>Action</th>
        <th>abc</th>
        <th>xyz</th>
    </tr>
</thead>
<tbody>
    <tr><td>hihi</td>
        <td>hihi</td>
    </tr>
</tbody>
</table>

I set the div of width 500px, and under it I have p and table elemetns. The p element adjust to the width of the div, while the table has its own width, which doesnt necessarily adjust to fit into 500px. I don’t know how this works, can anyone explain it to me? Thanks

  • 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-25T06:53:25+00:00Added an answer on May 25, 2026 at 6:53 am

    By default, <table> elements adjust to auto fit their contents. If the contents don’t need the full container, the space isnt taken. You can change this behavior by styling the table with:

    <table style="width: 100%;">
    

    In which case it will take all available width if possible.

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

Sidebar

Related Questions

Given the following HTML <div style=width: 500px; height: 500px; border: 1px solid red;> <div
Please consider the following: <td style=width: 500px;> <div style=width: 400px;>SomeContent</div> </td> For some reason,
it would be like this : <div id=map_canvas style=width: 500px; height: 300px;float:left;></div> left:(<=300) top:(<=500)
<div style=width: 100px; height:50px; line-height:50px; overflow:hidden;> <p>A short line</p> </div> <div style=width: 100px; height:50px;
<style type=text/css> div#foo { background: #0000ff; width: 200px; height: 200px; opacity: 0.30; filter: alpha(opacity
<html> <head> <style type=text/css> div { border:1px solid #000; min-width: 50%; } </style> </head>
#mydiv { position:absolute; left:0px; top:0px; width:83px; height:83px; } <div id=mydiv></div> That's my style for
I have a draggable div element with a hover style. This works fine, but
Hihi, I am trying to create a slide down menu using DIV, but hit
<html> <head> <style type=text/css rel=stylesheet> * {margin:0;padding:0;} div#box {background-color:green;width:1000px;} /* #box {position:absolute;top:0;right:0;} */ /*

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.