html - How to ignore the extra white space in Google Chrome in a right aligned table row? -


i have table right align cells generated @ server side. each line within cell optional, enclosed in if-then statement @ server side.

the sample html shows 3 columns, first column faulty in google chrome. columns 2 & 3 correct, yet strange, because html same, except newlines , whitespaces.

when @ first column in google chrome notice right margin doesn't align 100% each line within cell.

this problems not exist in firefox or ie, in google chrome.

    <!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd">     <html xmlns="http://www.w3.org/1999/xhtml">     <head>     </head>     <body>         <table border="0" cellpadding="0" cellspacing="0" style="border: 1px solid #000000;">             <tbody>                 <tr>                     <td style="text-align: right;border: 1px solid #000000;">                         <span>not ok in google chrome</span>                         <br /><span id="c1">500.000,00 €</span>                         <br /><span id="c2">166.666,67 €</span>                         <br /><span id="c3">489.545,90 €</span>                     </td>                     <td style="text-align: right;border: 1px solid #000000;">                         <span>ok in google chrome</span><br />                         <span id="d1">500.000,00 €</span><br />                         <span id="d2">166.666,67 €</span><br />                         <span id="d3">489.545,90 €</span>                     </td>                                    <td style="text-align: right;border: 1px solid #000000;">                         <span>ok in google chrome</span><br /><span id="d1">500.000,00 €</span><br /><span id="d2">166.666,67 €</span><br /><span id="d3">489.545,90 €</span>                     </td>                                        </tr>             </tbody>         </table>     </body>     </html> 

generating html in different way not option.

how can make work in google chrome, not changing html, maybe setting styling or something?

just change html.

how hard can be? why can't change it?

this works without changing html, it's little silly:

td span {     display: block } td br {     display: none } 

your original code: http://jsbin.com/ipaca5
with fix: http://jsbin.com/ipaca5/2


Comments

Popular posts from this blog

c# - how to write client side events functions for the combobox items -

exception - Python, pyPdf OCR error: pyPdf.utils.PdfReadError: EOF marker not found -