PDA

View Full Version : Document Frame JPG



jcallen04
05-27-2008, 02:42 PM
1) Script Title: Document frame script

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex3/documentborder.htm

3) Describe problem: Is it possible to use this script to have an image file border the page instead of a particular color?

jscheuer1
05-27-2008, 04:45 PM
No. It's not really a script anyway. The wizard part is, but it just applies a border style to the body. The output of the wizard doesn't even go where it tells you to put it, and isn't the most efficient way of styling the body even if it were put in the right spot, which would be in the body tag, ex:


<body style="border:25px ridge red;">

not below it as it says to do on the demo page.

To make a frame for a page using an image would be more complex, and you would probably need 4 images. One each for the top, right, bottom, and left sides. Each of the images would need to be of the sort that can look good when repeated. You would probably also need 4 corner images. Once you had all of that, you could set up a sort of box around the page using divisions). Some or all of the images would then be used as background images for the outer edge of this box, with the corners possibly as images, or background images. Getting the height right on a valid page when there is less content than window would be tricky. This could probably all be worked out, and in fact, if you were to Google the idea, you might find a solution, but there would be a lot of stuff relating to frame objects and framing pictures. However, as I say, no, not with this this simple approach as is used for the border effect.

jcallen04
05-27-2008, 05:02 PM
Here is an example of what I want to accomplish. I am new to coding so it is tough for me to breakdown the code they are using.

http://www.babylegs.net/

jscheuer1
05-28-2008, 04:02 PM
That baby legs site doesn't really have an image for a border for the site. It has one main background image (the green polka dot thing), and uses several different images inside the the page as borders for various elements. This (other than the use of the main background image) is not anything standard, and pretty much has to be worked out on a case by case basis depending upon how it is all supposed to work with the rest of the design.

To have a background image, just do:


<body style="background-image:url(some.jpg);">

Or better yet place the rule in a stylesheet. You can create other images as backgrounds for other parts (elements) of your page(s) as you see fit.

Google:

css style

or:

background image css style

for more ideas/info.

jcallen04
05-28-2008, 11:57 PM
Great. Thanks a lot.