The line
td img { text-align: center }
won't work. It has to target the td
instead: the td
having an img
element will have text-align: center
. Can it be done in CSS 2.1?
The line
td img { text-align: center }
won't work. It has to target the td
instead: the td
having an img
element will have text-align: center
. Can it be done in CSS 2.1?
Can you use jQuery? If you can then you can use a jquery selector to add a class to the td that will center it.
something like this untested code;
$('td img').parent().addclass('center');
Cannot be done without the help of JS or...
Add a class to the td:
<td class="img"><img .../></td>