pros and cons of DIV based web page?

Posted on 2010-01-08
Last Modified: 2013-11-19
Hi, what is pros and cons of DIV based web page? and which better the TABLE based html page or DIV based html page?
Question by:Abdu_Allah
    LVL 11

    Accepted Solution

    LVL 40

    Assisted Solution

    LVL 3

    Author Comment

    Guys I need your personal opinions and what do you use?
    LVL 40

    Assisted Solution

    i normally use tables because they are easier to manage.
    LVL 5

    Assisted Solution


    We can use <div> or <table> with respect to our needs.

    I am using <div> more than table, because, if will take a little bit more loading time as the <table> depth increses.


    <table><tr><td><table><tr><td><table> .... etc (<table> inside table row again <table> inside table row.. so as the depth increases it will affect the loading time.. not that..but will impact loading speed.)

    An advantage for the <table> is we can well organize the web pages with <tables> other than <div>'s

    and <div> is haivng a line break, so we need to use styles if we want to display to <div>'s in the same line, if we are using <table>, we can do with two table rows.

    I think, you will get some idea now..

    If you need any more details, please let me know.

    Thank you
    LVL 1

    Assisted Solution


    I prefer to use <div>, because <div>'s is more flexible. You have to know CSS, but if you do you can place a <div> pretty much wherever you like on your page by changing a few CSS-properties. If you use <table> you basically have to change most of the structure of the table to make any larger changes by copy-paste content from one cell to another and maybe change a lot of rowspans and colspans.

    If you're using <table> on the other hand, you don't have to know any CSS to create a good design.

    So, my advise is to use <div> if you're good at CSS and <table> if you're not.

    Hope it helped.
    LVL 11

    Assisted Solution

    I generally use <table> unless a specific requirement from customers for <div>.

    <table> is easy to manage. but if your customers are specific about page size specific then go for div. it will help when you show large data in a single page

    LVL 52

    Assisted Solution

    by:Carl Tawn
    I used to use tables for layout, but nowadays only use them for actual tabular data. Mainly this is because of accessibility guidelines (Section 508 in the US) and the way that screen reader software interprets page data. If you're dealing with public sector (i.e. government, NHS, universities, etc) then this becomes a major issue.

    Styling and layout with DIV elements takes a bit of getting used to and takes a little more effort than sticking everything in a table, but the effort is worth it.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    What is Node.js? Node.js is a server side scripting language much like PHP or ASP but is used to implement the complete package of HTTP webserver and application framework. The difference is that Node.js’s execution engine is asynchronous and event…
    Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
    The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
    The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

    794 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now