Topic: Positioning SimpleViewer in a table (HTML)


Just uploaded the SimpleViewer to my client's site with no issue, but I'd like to use the "position" trick to place the Gallery OVER the image in the table cell with it (I use it for text boxes with no issue). What I use looks similar to:

<div position: "relative"; left: "140px"; top: "-415px";>

Because it normally shows up below the image, I use a negative number for the "top" to trick it.

I've tried placing the embed code inside a <div></div> with the position attributes, and have even added the position attributes wherever I saw that looked appropriate, but couldn't get the slideshow to move up and over the image.

Kind of in a hurry on this one, so any help would be greatly appreciated! Thanks!

This is what I have currently- any idea on how to fix this?

Re: Positioning SimpleViewer in a table (HTML)

The correct syntax for something like this:

<div position: "relative"; left: "140px"; top: "-415px";>

... should be:

<div style="position: relative; left: 140px; top: 415px;">

Also, your page should use a Doctype Declaration. Please see here for details. I would start by trying the HTML5 Doctype Declaration.
Place the following code at the very top of your HTML document (before the opening <html> tag).


Your page also has other code errors (a <centre> tag before the <html> tag, code between the <head> and <body> sections and lines such as:

<script type="text/javascript" position: "relative"; left: "140px"; top: "-415px";>

... which should be replaced with:

<script type="text/javascript">

You can validate your page with the W3C Markup Validation Service and fix the errors reported.
Once your code validates, it should be rendered with greater predictability and consistency across different browsers.

With regard to your gallery, you could try setting the dimensions for the <td> into which you are embedding the gallery to whatever you like and then set the dimensions of the gallery itself to 100% x 100% so that it fills its parent container.
You could then perhaps use the CSS background-image property to display your image as the background of the gallery's container (rather than display the image using an <img> tag and then try to place the gallery on top of it using relative positioning).

Steven Speirs
SimpleViewer Support Team.

Re: Positioning SimpleViewer in a table (HTML)

Well I feel stupid. The gallery works like a charm now- it's been a long time since I've done any html work, so thanks for the pointers! I'll be sure to go in and undo all of those extra "position" attributes I put in there- got a little frustrated and started pasting them all over the embed code smile

Thanks again!