PDA

View Full Version : loading a doc within a doc with css



slimatron
06 Oct 2006, 09:08 AM
I have a website I'm working on:
www.andydavis3d.com
The basic model for the 3d gallery works ok.
But it's way too slow.
It's built using flash so my mate told me I needed to do it using CSS instead.
Each model in the gallery would need to have it's own html page presumably.
So how do I load an html page into an existing frame using CSS?

I am aware of iframes, but they are nasty, what's the neat CSS way of doing it?

Wickham
06 Oct 2006, 10:03 AM
HTML pages can be loaded with the Object tag. See
http://www.wickham43.supanet.com/tutorial/imageswithascrollbar.html
However, IE6 insists on putting a border around it which it seems impossible to get rid of. Also any links inside an object when clicked will open inside the object which probably won't be big enough, although this doesn't apply in your case.

The alternatives are not CSS (not directly, anyway).
Javascript
or server side includes SSI such as PHP where a code in the HTML page results in the host server inserting code from another file before downloading (it would normally be just the code relevant to the image or whatever, not a whole HTML file. In other words you just cut a slice of code out of your current HTML and put it in a separate file and substitute PHP code to identify the place and other file). See PHP board on this website.