Originariamente inviato da rickystra
lo style dovrebbe stare nell'head.
no, funziona anche fuori dall'head, infatti se metto un numero statico al posto di quello dinamico l'immagine me la stampa, solo che mi stampa sempre la stessa, è solo quello il problema che ho.

<style type="text/css">
.555{
background-image: url(images_photogallery/<?=$row['foto']?>);
background-repeat: no-repeat;
background-position: center;
width: 200px;
}
</style>


<table width="10" height="10" border="0" cellpadding="5" cellspacing="0">
<tr>
<td class="555"><a href="images_photogallery/<?=$row['foto']?>" rel="lightbox[roadtrip]">
[img]images/pixel_trasparente.gif[/img]</a></td>
</tr>
<tr>
<td align="center">


</td>
</tr>
</table>



SE INVECE INSERISCO UN NUMERO DINAMICO NON MI STAMPA NIENTE


<style type="text/css">
.<?php echo $row['id_photogallery']; ?>{
background-image: url(images_photogallery/<?=$row['foto']?>);
background-repeat: no-repeat;
background-position: center;
width: 200px;
}
</style>


<table width="10" height="10" border="0" cellpadding="5" cellspacing="0">
<tr>
<td class="<?php echo $row['id_photogallery']; ?>"><a href="images_photogallery/<?=$row['foto']?>" rel="lightbox[roadtrip]">
[img]images/pixel_trasparente.gif[/img]</a></td>
</tr>
<tr>
<td align="center">


</td>
</tr>
</table>