Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 9 of 9
  1. #1
    New Coder
    Join Date
    Sep 2007
    Posts
    59
    Thanks
    7
    Thanked 0 Times in 0 Posts

    CSS Print Stylesheet issues

    I have implemented a stylesheet for printing, but when you print it, there are 2 pages, but the second page is completely blank. Can I force it to print just 1 page.

    My other question on this same page, is in firefox it looks fine, but in Opera and IE the page goes on forever. Is there a way to fix this?

    Thanks everybody.

    http://www.lincolnsafari.org/registration.html

  • #2
    Regular Coder
    Join Date
    Feb 2007
    Location
    Canada
    Posts
    924
    Thanks
    10
    Thanked 56 Times in 55 Posts
    Start here:

    http://www.w3.org/QA/2002/04/valid-dtd-list.html

    Put a valid Doctyupe on the page. It will avoid Quirks mode and (hopefully) make it easier to design for cross Browser performance by having all the browsers use the same rules. Well, at least it removes a bunch of issues.

    Then run the page through the w3c validator. Couple of errors on the page need cleaning up. That might help.

  • #3
    New Coder
    Join Date
    Sep 2007
    Posts
    59
    Thanks
    7
    Thanked 0 Times in 0 Posts
    Which doctype would I use?

    This one?

    <?xml version="1.0" encoding="utf-8"?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

  • #4
    Regular Coder BWiz's Avatar
    Join Date
    Mar 2006
    Location
    Sol System
    Posts
    471
    Thanks
    7
    Thanked 21 Times in 21 Posts
    You should be using XHTML, however HTML is fine depending on what your trying to achieve.

    My preference is to use XHTML 1.0 Strict, however other doctypes are fine as well.
    BWiz :: Happy Coding!
    2006
    2007 2008 2009
    2010 2011
    Irrational numbers make no sense.

  • #5
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,858
    Thanks
    160
    Thanked 2,223 Times in 2,210 Posts
    Blog Entries
    1
    But don't use <?xml version="1.0" encoding="utf-8"?> at the top, since it'll cause IE to go in to quirks mode
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #6
    New Coder
    Join Date
    Sep 2007
    Posts
    59
    Thanks
    7
    Thanked 0 Times in 0 Posts
    I added the doc type, and when I try to validate the css, I get this error:

    Servlet has thrown exception:javax.servlet.ServletException: Timed out

    What does that mean?

  • #7
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    It just means the validation server is having issues. Try it again.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #8
    New Coder
    Join Date
    Sep 2007
    Posts
    59
    Thanks
    7
    Thanked 0 Times in 0 Posts
    Aerospace do you know if there is a way to force a print stylesheet to only print 1 page, even though it thinks there is something on page 2?

    And do you know why in Opera the page goes on forever?

  • #9
    Regular Coder
    Join Date
    Feb 2007
    Location
    Canada
    Posts
    924
    Thanks
    10
    Thanked 56 Times in 55 Posts
    there seems to be some 'blank' stuff at the bottom of the page. The print selection is likely trying to spew that out, too. Review the Heights on the elements.

    Last edited by jlhaslip; 10-30-2007 at 09:10 PM. Reason: forgot the image


  •  

    Posting Permissions

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