Forum: Ruby on Rails html question

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
C1e5a9e9344b6d31b9df7303e6dc378a?d=identicon&s=25 Craig White (Guest)
on 2006-02-11 21:25
(Received via mailing list)
Just to show my versatility in things that I don't understand, I'm
struggling with 'printing' html and I don't exactly know how to handle
this. On screen...I have no problems but print preview - I have a
problem

Consider 2 layers defined in <head>

#layer1 { height: 118px; width: 100px; left: 36px; top: 20px; position:
absolute; visibility: visible; }
#layer2 { height: 150px; width: 752px; left: 36px; top: 20px; position:
absolute; visibility: visible; }
--></style>
  </head>
    <body>
      <span id="layer1">
         <img src="/images/pic.gif" alt="" height="112" width="128"
          border="0" />
         <span id="layer2">
           <h2>Some text<</h2>
         </span>
      </span>

In print preview...text in layer2 is 'below' rather than inline with
picture in layer1. Inside a browser window, the objects are perfectly
where I want them...until I print/print preview.

I have tried both <span> and <div> tags but the same results.

I am trying not to 'force' the location with <table> as I am trying to
reform my ways.

What is the trick?

Craig
This topic is locked and can not be replied to.