I have a code to create wrapper divs containing elements I want to be vertically centered. Ok. This works fine for me, I can have a given height for top-parent container or a given height for one of the elements contained (img, span, etc). I have always a right vertically centered of elements (this is what I want)
But however I have this error.
The widths of divs have an arbitrary value, as if the browser distributed the space. I cannot use 'float' because then the table-trick does not work.
The next example I have three divs and I have arbitrary widths.... I'd like the first and second divs aligned to the left, and the third to the right. But I can't use float ,, this is the code ( the imgs are 'cut' , but you can see the pseudo-image)
<div style="display: table; width: 200px; background-color: #0099CC;">
<div style="vertical-align: middle; display: table-cell;">
<img src="data:image/png;base64,iVBORw0KGg..."=" width="32" height="82"></div>
<div style="vertical-align: middle; display: table-cell;">
<span>Load file</span></div>
<div style="display: table-cell; text-align: center; vertical-align: middle;">
<img src="data:image/png;base64,iVBORw0KGg..."=" width="32" height="32"></div>
</div>
Any idea would be really appreciated,