HTML Table -> Page Print

Discussion in 'HTML' started by rehanbasar, Aug 3, 2006.

  1. rehanbasar

    rehanbasar Guest

    I have implemeted header and footer on asp page using <th> and <tf>
    > tags. Is there any way possible through which I can restrict a table (within a table) or a row of table completely on one page. That means either it would print completely on page1 or page 2.



    ThnX in advance
     
    rehanbasar, Aug 3, 2006
    #1
    1. Advertising

  2. rehanbasar wrote:
    > I have implemeted header and footer on asp page using <th> and <tf>


    There is no such element as <tf> in HTML.

    > tags. Is there any way possible through which I can restrict a table
    > (within a table)


    A what? http://dorward.me.uk/www/nested/

    > or a row of table completely on one page. That
    > means either it would print completely on page1 or page 2.


    Take a look a the page-break-* properties in CSS 2. Browser support is
    somewhat variable.

    http://w3.org/TR/CSS2/
     
    David Dorward, Aug 3, 2006
    #2
    1. Advertising

  3. rehanbasar

    Andy Dingley Guest

    rehanbasar wrote:

    > I have implemeted header and footer on asp page using <th> and <tf>
    > tags.


    You'd be better using the <thead> and <tfoot> tags, which exist and are
    valid.
    http://www.w3.org/TR/html4/struct/tables.html#edef-THEAD

    Even though it exist, don't use <th> for this. <th> isn't a header,
    it's a _header_cell_. It behaves like a cell not a row. Also you can
    potentially use it anywhere you want this formatting.

    > Is there any way possible through which I can restrict a table (within a table) or a row of > table completely on one page. That means either it would print completely on page1
    > or page 2.


    This is unreliable and awkward, owing to browser problems. The CSS
    page-break-inside : avoid;
    rule is where to start looking
    http://www.w3.org/TR/CSS21/page.html#page-break-props
     
    Andy Dingley, Aug 3, 2006
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Bernard Segonnes

    Print and print overview and current page

    Bernard Segonnes, Nov 4, 2004, in forum: Java
    Replies:
    0
    Views:
    455
    Bernard Segonnes
    Nov 4, 2004
  2. Sam
    Replies:
    1
    Views:
    657
    seigo
    Nov 10, 2006
  3. Ben
    Replies:
    5
    Views:
    5,298
  4. keto
    Replies:
    0
    Views:
    964
  5. David Cournapeau

    print a vs print '%s' % a vs print '%f' a

    David Cournapeau, Dec 30, 2008, in forum: Python
    Replies:
    0
    Views:
    363
    David Cournapeau
    Dec 30, 2008
Loading...

Share This Page