Image padding prevention / issue

C

Carl Gilbert

Hi

I have a fairly basic page the consists of a few tables and some images.

I have one table in the center of the page and I am setting the border,
cellpadding and cellspacing to zero.
I am also setting the border to ridge and setting a background image.

The dimensions of the table are 800x533 and the same applies to the image
that I am using for the background.

All is fine when there is just the table and the background image.

Now if I put an transparent image in the table using <TR><TD><IMG...> etc,
and set this image to 800x533, the height of the table increases slightly.

Say I then put 5 or 6 transparent images in the table and set their heights
to total 533 exactly, the table will increase by 5 or 6 times more than when
I had just one image in the table.

The result is that the image in the background will now start to draw a
second time in a tile effect in order to fill the table area.

I think what is happening, is when I add an image, there are some padding
issues with the images so even though the images within the table add up to
533, the area in which they actually take up is more like 550 or 560
depending on the number of images being stacked up.

Is there anyway to prevent the form from putting such padding on images so
that they line up next to each other rather than leaving a gap?

Regards, Carl Gilbert.
 
M

Mark Parnell

Previously in alt.html said:
Hi
G'day.

I have a fairly basic page the consists of a few tables and some images.

Right answer: Drop the tables for layout and the transparent images and
learn CSS.

Short answer: This is good[1]:

<td><img ...></td>

This is not:

<td> <img ...> </td>

Nor is this:

<td>
<img ...>
</td>

[1] Good in the context of that answer - the right answer is obviously
much better.
 
N

Neal

Carl:
I have a fairly basic page the consists of a few tables and some images.
... prevent the form from putting such padding on images so
that they line up next to each other rather than leaving a gap?

A URL is worth a thousand words.
 
A

Augustus

Carl Gilbert said:
Hi

I have a fairly basic page the consists of a few tables and some images.

You are going to alot of trouble to protect your images...

The thing is:
When it comes to "Joe Average User" your method, like every other method,
might work... but then again it might not.

But the problem is: when it comes to the people that matter (people that
will take your images and use them on websites or in graphic/print media,
etc) none of the methods will work.

In short: you are wasting your time... because anybody who really wants
your images for an ulterior motive will already know how to get them or be
able to easily find out

Put a transparent image over your image? Doesn't work: they can right click
the image and instead of clicking "save image as" they just choose "save
background as". Or they can go into their cache

Disable right click? Doesn't work: they can just turn scripting off. Or
they can go into their cache

And even if you came up with some super innovative way to protect your
images and prevented them from being cached on the users computer... they
can always just fall back on good ol' screenshot. I just press the "Fn" key
and "PrtSc" and go in to Photoshop and voila, I got your picture (if you
picture is bigger than the screen then I just take multiple shots and piece
them together)
 
R

Richard

Carl said:
I have a fairly basic page the consists of a few tables and some images.
I have one table in the center of the page and I am setting the border,
cellpadding and cellspacing to zero.
I am also setting the border to ridge and setting a background image.

Table cells have a tendency to increase when you add more than what you
designed them to hold.
Your first mistake is setting the cell size to the same size as the image.
Then you set the padding to zero.
So why not just turn the borders off?
Your next mistake is the size of the image.
Now you want to compound the issue of adding in yet more images while you
want the table cell to remain the same size?
Ain't gonna happen.
If you would learn a little simple CSS, you could manage the images with
divisions much easier.
 

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

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top