Results 1 to 4 of 4

Thread: Best option between div and table

  1. #1
    Join Date
    May 2013
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Best option between div and table

    Which is the best option between div and table for a webpage layout? I am feeling confusion to use it. Please reply me.

  2. #2
    Join Date
    Jul 2008
    Location
    Derbyshire, UK
    Posts
    1,999
    Thanks
    16
    Thanked 315 Times in 313 Posts
    Blog Entries
    12

    Default

    If you Google something like "table vs div layouts" you'll find many answers, but the basics are listed below;


    CSS layouts use less markup: All styling and formatting can be removed from a web page and stored in an external CSS file, which leads to smaller page sizes. Additionally, eliminating tables also means eliminating those extra markup tags - table, tbody, th, tr and td are simply replaced with one div, thus reducing the page size yet again!

    CSS layouts load faster: An external stylesheet can be cached by a web browser, meaning that it is downloaded once and then stored in reserve to use on the next page. Used in conjunction with divs, CSS leads to speedy and progressive page views. Tables, on the otherhand, need to download in full before a web browser can display the contents, so on slower internet connections, there is a significant delay before anything pops onto the screen.

    CSS offers more design potential: CSS design isn't restricted in the same way that rigid, grid-based table layouts are. Why limit your design to something that looks at home in an Excel spreasheet? Open yourself to a world of creativity!

    CSS layouts are easier to update: Changing the look of your website is easier and faster with CSS. Since CSS can be stored in one, site-wide file, it's easier to locate elements that need updating and that change instantly filters down to every page of your website. If you've used a table-based layout, you'll need to update every page of your website to deploy a global change.

    CSS saves you money (and earns you money): Smaller page sizes means less bandwidth consumption (saves on web-hosting fees). It also means more page views; Visitors don't get impatient and leave they browse more they buy more!

    CSS increases your search engine visibility: Smaller pages with simpler, less-bloated markup, are easier for web-spiders to index so they zip around your website and give good marks for clear content separation, etc. Consider all those extra visitor-clicks too and your page rank gets another well-deserved boost!

    CSS can give you the edge in the job market: If you show a prospective employer that you can use CSS effectively, it proves that you can offer clients modern design solutions that will in turn give them the market edge. Employer looks good. Developer looks good. Client looks good. Everyone's happy!


    So, keep tables for statistical data, and use CSS for your web design. And if your really must use tables somewhere in your web layout, try to keep them to an absolute minimum - no tables inside tables, inside tables, like a stack of Russian dolls - nested tables can get ugly and are horrible to troubleshoot if things go wrong.
    Focus on Function Web Design | Latest News RSS | Facebook | Twitter |
    Fast Edit (A flat file, PHP web page editor & CMS. Small, FREE, no database!) | Fast Edit BE (Snippet Manager) (Web content editor for multiple editable regions!) | Fast Apps |
    The only limit to creativity is imagination: JemCon.org

  3. #3
    Join Date
    May 2013
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks a lot but I have completed my html course now, I think with css tutorial I will be more clear about the topics. Am I right?

  4. #4
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    29,070
    Thanks
    44
    Thanked 3,216 Times in 3,178 Posts
    Blog Entries
    12

    Default

    Only if you learn the material. Then yes.

    Since this has been answered, I'm closing this thread because this question is a bit too general in the first place. If you need help with your page, please open a new thread and provide us with the code or, better yet, a link to the problem page.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

Similar Threads

  1. Max function using where option
    By hemi519 in forum MySQL and other databases
    Replies: 1
    Last Post: 07-23-2011, 01:35 AM
  2. Replies: 4
    Last Post: 01-18-2010, 01:42 PM
  3. Using JS To Do A Only Once Option
    By kmaven in forum JavaScript
    Replies: 1
    Last Post: 05-25-2008, 05:28 AM
  4. js in <option>
    By toe_head2001 in forum HTML
    Replies: 4
    Last Post: 12-26-2005, 05:16 PM
  5. copy records from table to table in MySQL?
    By nephish in forum Other
    Replies: 0
    Last Post: 07-29-2005, 07:40 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •