How would I create a template that the center extends when text is added?

B

Bruce

I have a web site (http://www.YourRoamingNotary.com )
I would like to present the text in a paper scroll (jpeg image).
I need to have the center section of the scroll vary length depending on how
much text is on the page. I would also like it to properly size as somebody
changes the size of their browser.

Currently, I have created a table that has 3 sections-each with a background
picture- a top for the top of the scroll, middle for the body, and a bottom.

This does not work the way I want it to. If somebody does not have the
browser at just the right size, then the right edge of the picture gets cut,
or a second image is displayed.

from my research, it looks like I want to create a CSS template to do this,
but I am not sure how to did what I want. I am not familiar with CSS at all.
It would be OK to have the whole page as the scroll, but I would really
prefer to have just the body, either way is OK though

Thanks!
Bruce
 
R

Ronx

You need a fixed width layout, with the images for the scroll as
background images for the fixed width part. An example using a table:

<body>
<div style="width:700px;margin:0 auto;">
<table
style="width:100%;margin:0;border:none;border-collapse:collapse;">
<tr>
<td><img src="scroll-top.jpg" alt="scroll top" width="700"
height="150"></td>
</tr>
<tr>
<td style="background:url(scroll-middle.jpg) norepeat;padding:10px
25px;">text goes here</td>
</tr>
<tr>
<td><img src="scroll-bottom.jpg" alt="scroll bottom" width="700"
height="150"></td>>
</tr>
</table>
</div>
</body>

The above assumes the scroll images are all 700px wide, and the text is
placed 25px away from the image edges.

The page content is centered in all browsers.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top