Citat:
ctpaba:
evo pogledaj kako izgleda kad stavim kod kako si ti stavio :((( (ovo u sredini)
Pogledao, uopste nisi stavio kako sam ja naglasio :(. Dakle, osnovne razlike:
-ako ostavis this.style.background=' ' - i ne stavis pozadinsku boju, ostae ona crvena boja (barem ostaje u operi), ako stavis #ffffff vraca se na belu.
-i dalje nemas align="center" kod td taga.
Citat:
slike se jos vise udalje a treba da budu spojene kao sto su ove velike dole da to izgleda kao lanac!
Slike ti se u ovom slucaju udaljavaju zbog toga sto nemas align za sliku, pa tekst umesto da ide oko slike, on je malo ispod slike, i on ti pravi "prazninu" izmedju celija, i zato ti one ne izgledaju kao lanac.
Citat:
nisam naveo pozdainu jer u pozadini table je jedna slika i zato sam onmouseout="this.style.background=' ' ostavio prazno da mi vrati pozadinu koja je bila i ranije (zato je slika gif sa transparentnom pozadinom)
Mozda to radi u IE-u, u Operi (a verovatno i u NN-u) to ne radi, jer kad ima prazno on ostavi ono sto je poslednje bilo, u tvom slucaju crvenu boju #DD002B.
Evo ti resenja, ako hoces da ti stoje centrirano slike kao lanac i da imas linkove sa desne strane od slika:
Code:
<table bgcolor="#FFFFFF" valign="center" border="0" width=100% cellspacing=0 cellpadding=0 align="center">
<tr>
<td onmouseover="this.style.background='#DD002B'" onmouseout="this.style.background='#FFFFFF'" align="center">
<img src="http://www.ctpaba.com/test/imgs/center.gif" border="0" width="70" height="48" align="middle"><a href=test.htm>T E S T</a></td>
</tr>
<tr>
<td onmouseover="this.style.background='#DD002B'" onmouseout="this.style.background='#FFFFFF'" align="center">
<img src="http://www.ctpaba.com/test/imgs/center.gif" border="0" width="70" height="48" align="middle"><a href=test.htm>T E S T</a></td>
</tr>
</table>
Ako hoces sve levo - onda se to adekvatno podesi, ako ne znas to da podesis - mani html kodiranje :) Ostaje ti jos da dodas sliku za gore (onu koja je bez spajanja jedno na drugo). Oko slika je stavljen align middle, sto znaci da ce se tekst pojaviti desno na sredini slike. Ima tu jos opcioja ali me mrzi sad da se podsecam koje su. Ukoliko hoces tekst malo dalje od slika, onda imas i wspace i hspace ili kako vec bese, prostudiraj to malo pa probaj (hspace, space ce da ti udalji slike jednu od druge pa nece biti kako si zamislio). Dakle, evo malo izvoda:
Citat:
13.7.4 Alignment
The align attribute specifies the position of an IMG, OBJECT, or APPLET with respect to its context.
The following values for align concern the object's position with respect to surrounding text:
bottom: means that the bottom of the object should be vertically aligned with the current baseline. This is the default value.
middle: means that the center of the object should be vertically aligned with the current baseline.
top: means that the top of the object should be vertically aligned with the top of the current text line.
Two other values, left and right, cause the image to float to the current left or right margin. They are discussed in the section on floating objects.
Differing interpretations of align. User agents vary in their interpretation of the align attribute. Some only take into account what has occurred on the text line prior to the element, some take into account the text on both sides of the element.
Jesmo sad resili problem, i... kad vodis na pivo?
P.S. BTW. Oni -ovi ne trebaju kad postavlajmo na strdinu, ostavio sam ih samo jer me mrzelo da ih brisem.. ;)
P.P.S. Ovaj kod radi u IE i Operi, u NN-u prikazuje lepo, ali ne radi javascript deo.
Kad sve ostalo zakaže, pročitaj uputstvo...