HTML madness - Width collapse and stubborn tables - html-table

I'm trying to make a newsletter sort of thing and this piece of bovine defecation won't stay the width I specify. I've already set the width in 100 different places and whenever I preview it on Outlook it completely stretches out to infinity.
I do have a "width:100%" piece of code here but It's inside the master div, and the master div specifies the width clearly so the child element should obey this size when setting it as 100%. Should be relative to the parent element.
It's driving me crazy. I'm editing this in Joomla 1.5 to top it off, which is seemingly annoying as dgwergh. Doesn't even let me make a style section and I can't think of another free way to edit and send html newsletters to thousands of people while presenting statistics for free.
And upgrading it is annoying as egewg because I need to test it in a different domain first which I don't have.
Here's my code:
<div style="font-family: century gothic;" align="center">
<table style="width: 600px; background-color: #ffffff; display: block;" border="0" cellspacing="0" cellpadding="0" bgcolor="#FFFFFF">
<tbody>
<tr>
<td rowspan="1" colspan="1" align="center" valign="top">
<table style="width: 600px; height: 0px;" cellspacing="0" cellpadding="0">
<tbody>
<tr style="line-height: 0px;">
<td>
<table style="margin-top: 0;">
<tbody>
<tr style="line-height: 0px;">
<td style="line-height: 0px; height: 83px; margin-top: 0; width: 600px;"><img src="" alt="SEMINARIO-header-14julho2014" width="100%" height="auto" /></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="background-color: #fff; padding: 2px; width: 600px;" rowspan="1" colspan="1" align="left" valign="top" bgcolor="#000000">
<table style="width: 100%; vertical-align: middle;" border="0" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="padding: 0px; width: 600px;" rowspan="1" colspan="1" align="left" valign="top" width="600"></td>
</tr>
<tr>
<td style="background-color: #ffffff; width: 600px;" rowspan="1" colspan="1" align="left" valign="top" bgcolor="#FFFFFF" width="600">
<table style="display: table; width: 100%; font-family: century gothic; vertical-align: middle;" cellspacing="0" cellpadding="3" bgcolor="#888888">
<tbody>
<tr>
<td style="width: 600px; text-align: center; font-family: century gothic; color: #ffffff; vertical-align: middle;" rowspan="1" colspan="1" align="center" valign="top">
<div style="font-family: century gothic; vertical-align: middle;">
<div style="font-family: century gothic; vertical-align: middle;">
<div style="font-family: century gothic; vertical-align: middle;"><span style="font-family: 'century gothic'; font-size: 16pt;"><br /></span></div>
<div style="font-family: century gothic; vertical-align: middle;"><span style="font-family: 'century gothic'; font-size: 16pt;">SEMINÁRIO</span></div>
<p style="font-family: century gothic; font-size: 18pt; color: #eaeff4;"><strong style="color: #ffffff; background-color: transparent;">BIM & MODELAÇÃO DE ESTRUTURAS</strong><span style="color: #ffffff; font-size: 14pt; background-color: transparent;"><strong> </strong></span><span style="font-size: 16pt; color: #ffffff; background-color: transparent;"> </span></p>
<p><span style="font-size: 10pt;"> | 14 de Julho de 2014 | 15h30 - 18h30</span></p>
</div>
<div><span style="font-size: 14pt;"> </span></div>
</div>
</td>
</tr>
</tbody>
</table>
<table style="display: table; width: 100%; background-color: #efefef; font-family: century gothic; size: 8pt;" cellspacing="6" cellpadding="1">
<tbody>
<tr>
<td style="width: 600px; text-align: left; color: #000000;" rowspan="1" colspan="1" align="left" valign="top">
<div style="color: #000; font-size: 10.8pt; font-family: century gothic; text-align: justify; padding: 10px;" align="justify">
<p>Caro projectista/engenheiro,<br /><br /> <br />A convida-o a assitir e participar no seminário gratuito de BIM & Modelação de Estruturas no dia 14 de Julho, dedicado especialmente a projectistas e engenheiros, cuja preocupação é resolver a crescente necessidade de eficiência no projecto de estruturas, mantendo um elevado controlo nos procedimentos de cálculo e dimensionamento estrutural.</p>
<p>Contamos com uma participação muito significativa de pessoas que utilizam no seu dia-a-dia aplicações de modelação e cálculo de estruturas da CSI, mas também de outras empresas igualmente prestigiadas do mesmo sector. Sabemos que os softwares de cálculo estrutural progridem dia após dia, mas no entanto, muitos engenheiros e projectistas não sentem que isso reflicta directamente em acréscimo de produtividade e eficácia do trabalho.</p>
<p>Gostaríamos de poder contar com a sua presença no seminário, para lhe apresentar as nossas poderosas ferramentas de cálculo, de uso intuitivo e eficaz, as quais acreditamos ser do seu interesse.</p>
<p>As inscrições no seminário BIM & Modelação de Estruturas, a ter lugar na Universidade Lusófona do Porto, ainda estão abertas. Gostaríamos de renovar o nosso convite (caso ainda não tenha feito a inscrição), porque acreditamos que no fim, irá dar por bem investido o seu tempo. Pedimos-lhe esse tempo na certeza de que, independentemente dos programas que use, ficará com uma ideia sólida sobre as valências actuais da oferta de software de uma das empresas líderes mundiais em modelação e cálculo estrutural.</p>
<p>Assim, reenviamos o link com o programa do seminário, na expectativa de o encontrar presente neste grande evento, que irá reunir vários projectistas e engenheiros.</p>
</div>
<div style="font-family: century gothic; text-align: justify;" align="justify"> </div>
<div style="text-align: center;" align="center"> </div>
<div style="text-align: center;" align="center"> </div>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="width: 100%;">
<table style="background-color: #507d90;">
<tbody>
<tr style="padding-bottom: 0px;">
<td style="width: 210px; height: 60px; padding-left: 5px;"><img src="" alt="csi logo" width="140" /></td>
<td style="width: 435px; height: 60px; text-align: right; color: #fff; font-weight: bold; font-size: 7pt;">
<p style="font-family: century gothic; padding-right: 5px;"><br />T: <br />E: <br />W:
</tr>
<tr>
<td style="text-justify: justify; line-height: 11px; font-family: century gothic; width: 640; padding-bottom: 20px; padding-left: 30px; padding-right: 25px; font-size: 7pt; color: #fff;" colspan="2">
<hr />
A mensagem que acabou de receber é um e-mail informativo da CSI Portugal, não devendo ser considerado como SPAM. De acordo com o Artº. 22 do Decreto lei 7/2004 de 7 de Janeiro, se o seu registo foi incluído na nossa lista de envio por erro ou se pretender simplesmente ser removido da mesma, por favor clique {unsubscribe}aqui{/unsubscribe}</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>

Remove all the width: 100% you have in your code. I tried this in Outlook and it displayed the 600px-wide block in the middle of the mail, which I assume is the result you want to achieve.
Also, the width of your footer lacks an unit : I corrected it width: 640px.
See http://jsfiddle.net/w6rHj/ for the small changes.

That code works for me when I copy and paste it into Outlook (I assume you mean the rebranded Hotmail rather than Outlook Express).
Some bug fixing tips
Try sending it without using Joomla to see if it is Joomla or Outlook that is causing the problem.
Try inspecting the css of the wide element in Firebug to see what styles it is inheriting. Outlook styles may be overriding your styles. Firebug also allows you to turn off styles until you can spot the problematic one.
View the source of the email when it is in Outlook and see if it differs - has it changed in any way.
Also, you haven't closed your div surrounding the table in the example above. Doubt this would cause it, however.

Related

React Native HTMLToPDF printing awkward character

So I have this HTML template to transform to pdf using the RNHTMLToPDF package:
export default function getPdfTemplate(requestData, items, switchValues) {
return `
<div style="display: flex; flex-direction: column; width: 100%;">
<div id="pdf-header" style="display: flex; flex-direction: row; width: 100%;">
<div style="display: flex; flex-direction: column; width: 50%;">
<div style="font-size: 10px"> <b>Nome do cliente: </b> ${requestData.nomeCliente} </div>
<div style="font-size: 10px"> <b>Código do cliente: </b> ${
requestData.codigoCliente
} </div>
<div style="font-size: 10px"> <b>Número do pedido: </b> ${requestData.numPedido} </div>
<div style="font-size: 10px"> <b>Gerado em: </b> ${new Date().toLocaleDateString()} via Sistema de vendas </div>
</div>
<div style="display: flex; flex-direction: column; width: 50%;">
<div style="font-size: 10px"> <b>Data da negociação: </b> ${moment(
requestData.dataPedido,
"YYYYMMDD"
).format("DD/MM/YYYY")} - ${requestData.horaPedido} </div>
<div style="font-size: 10px"> <b>Quantidade de itens: ${
requestData.quantidadeItem
} </b> </div>
<div style="font-size: 10px"> <b>Valor total do pedido: </b> R$ ${
requestData.valorTotalPedido
} </div>
<div style="font-size: 10px"> <b>Valor do desconto negociado: </b> R$ ${
requestData.discount
} </div>
</div>
</div>
<hr style="margin: 14px 0 8px 0;">
<div id="pdf-table">
<h2 style="font-size: 10px; margin: 8px 0;">Lista de itens do pedido</h2>
<table style="background-color: #F3F3F4; width: 100%; border-collapse: collapse" >
<thead style="background-color: #656F7B;" >
<tr style="color: #FFF; font-size: 8px;" >
<th style="padding: 5px; font-size: 8px;">MERCADORIA</th>
<th style="padding: 5px; font-size: 8px;">QTDE</th>
<th style="padding: 5px; font-size: 8px;">COD BARRAS</th>
<th style="padding: 5px; font-size: 8px;">UNIT.LI+IMP</th>
<th style="padding: 5px; font-size: 8px;">TOL.LIQ+IMP</th>
<th style="padding: 5px; font-size: 8px;">COND PGTO</th>
<th style="padding: 5px; font-size: 8px;">VLR.FRETE</th>
<th style="padding: 5px; font-size: 8px;">FIL EXPED</th>
<th style="padding: 5px; font-size: 8px;">FIL FAT</th>
<th style="padding: 5px; font-size: 8px;">% DE ICMS</th>
</tr>
</thead>
<tbody>
${
items && items.length > 0 ? (
items.map(
(item, index) =>
`<tr style="line-height: 45px; background:${
index % 2 != 0 ? "#FFFFFF" : "initial"
}">
<td colspan="10" style="padding: 0px 10px; text-align:start; font-size: 8px;">${item.CODMER} - ${item.DESMER}</td>
<!--td colspan="9" style="font-size: 8px;"></td-->
</tr>
<tr style="margin: 4px 10px; line-height: 45px; background:${
index % 2 != 0 ? "#FFFFFF" : "initial"
}">
<td colspan="1" style="text-align:center; font-size: 6px;"> - </td>
<td colspan="1" style="text-align:center; font-size: 6px;">${
item.quantidadeMercadoria
}</td> <!-- qtd -->
<td colspan="1" style="text-align:center; font-size: 6px;">${
item.CODBRRMER
}</td> <!-- cód barras item -->
<td colspan="1" style="text-align:center; font-size: 6px;">
${(
item.VLRLIQMER +
item.VLRFRTMER +
item.stb.valorSTBTotal +
item.valorIPITotal
).toFixed(2)}
</td> <!-- Valor Unitário Líquido + Imposto + Frete -->
<td colspan="1" style="text-align:center; font-size: 6px;">
${(
(item.VLRLIQMER + item.VLRFRTMER) *
item.quantidadeMercadoria +
item.stb.valorSTBTotal +
item.valorIPITotal
).toFixed(2)}
</td> <!-- Total líquido + Imposto + Frete -->
<td colspan="1" style="text-align:center; font-size: 6px;">${
item.condicaoPagamento.codigoCondicaoPagamento
}</td> <!-- condição de pagamento -->
<td colspan="1" style="text-align:center; font-size: 6px;">${
switchValues.freightValue ? item.frete : ''
}</td> <!-- valor frete -->
<td colspan="1" style="text-align:center; font-size: 6px;">${
switchValues.exp ? item.CODFILEPD : ''
}</td> <!-- filial expedição -->
<td colspan="1" style="text-align:center; font-size: 6px;">${
switchValues.fat ? item.CODFILFAT : ''
}</td> <!-- filial faturamento -->
<td colspan="1" style="text-align:center; font-size: 6px;">
${
switchValues.icms
? item.mercadoria.percentualICMS
.percentualICMSMercadoria
: ''
}</td> <!-- percentual ICMS -->
</tr>`
)
) : null
}
</tbody>
</table>
</div>
<div id="pdf-footer">
<br>
<hr>
<h2 style="font-size: 10px;">Observações</h2>
<div style="border: 1px solid #9BA3A8; border-radius: 8px; margin: 8px 0; padding: 12px; font-size: 6px;">
** ATENÇÃO! As informações deste arquivo destinam-se a mera conferência da descrição, quantidade e valor (nesta data) dos itens pedidos, sendo certo que, até o faturamento da mercadoria, o pedido poderá sofrer alterações, seja pela falta de produto em estoque, por variações de alíquotas de ICMS, IPI, débitos do cliente perante o Fisco Estadual, entre outros motivos, razão pela qual este documento não vincula as partes.
</div>
<div style="border: 1px solid #9BA3A8; border-radius: 8px; margin: 8px 0; padding: 12px; font-size: 6px;">
** Informamos ainda, que o presente pedido encontra-se em aberto até a data do faturamento, pelo que V. Sa. poderá promover o cancelamento ou a inclusão de novos itens, o que poderá provocar a modificação dos percentuais de desconto, influenciando no preço final dos pedidos.
</div>
</div>
</div>
`
}
Printing this awkward comma character. I can't find it anywhere in the respective HTML
Any reason for this mystery?
Found the problem
Just had to add a join at the end of the map function item.map(el...).join('')

Code Block with table not showing on Mailchimp

I am building an email template on Mailchimp using code blocks in some parts. I have created a seemingly simple table which does show on the visual composer but does not show when I click on Preview or Test.
This is a standalone block, so I don't think I need to insert table anywhere but within a div element. After previewing the entire template and returning to the visual composer, the table disappears but does re-appear after clicking on the element below.
Is there any reason why this happens?
<div class="mcnTextContent" style="margin-left:64px; margin-right:64px">
<table style="font-size: 18px; font-family: Arial, Helvetica, sans-serif; font-color: #1F1F1F; width: 100%; margin-left: auto; margin-right: auto;" border="0">
<tbody>
<tr>
<td style="line-height: 0px !important; padding-bottom: 48px !important;" colspan="3"> </td>
</tr>
<tr>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">Year Launch</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">2020<br/>UCITs version - 2015</span></td>
<td colspan="2"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">Assets Under Management</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">USD $1B strategy<br/>UCITs version - SD $0.4B</span></td>
</tr>
<tr>
<td style="line-height: 0px !important; padding-bottom: 20px !important;" colspan="3"> </td>
</tr>
<tr>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">Performance 2020</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">5.49%<sup>2</sup></span></td>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">YTD Performance</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">0.50%<sup>1</sup></span></td>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">Yield-to-Worst</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">8.95%<sup>2</sup></span></td>
</tr>
<tr>
<td style="line-height: 0px !important; padding-bottom: 20px !important;" colspan="3"> </td>
</tr>
<tr>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">Duration</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">4 years<sup>1</sup></span></td>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">3-year Volatility</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">7.23%<sup>2</sup></span></td>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;"># of Positions</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">144<sup>3</sup></span></td>
</tr>
<tr>
<td style="line-height: 0px !important; padding-bottom: 20px !important;" colspan="3"> </td>
</tr>
<tr>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">Gross Yield (USD)</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">442%<sup>2</sup></span></td>
<td width="33%"><span style="font-size: 10px !important; vertical-align: middle;">🟢 </span> <span style="font-weight: bold;">MTM Yield (USD)</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">45%<sup>2</sup></span></td>
<td> </td>
</tr>
<tr>
<td style="line-height: 0px !important; padding-bottom: 20px !important;" colspan="3"> </td>
</tr>
<tr>
<td style="font-size: 12px !important; line-height: 16px;" colspan="3"><sup>1</sup> Source: Morningstar Direct March, 5th, 2021 (HI USD shareclass).<br/> <sup>2</sup> Source: TwentyFour, Bloomberg; February 28th, 2021.<br/> <sup>3</sup> This is now credit issuers only so it excludes ABS and Government (total credit positions = 271). Source: TwentyFour Bloomberg Feb 28th 2021.</td>
</tr>
<tr>
<td style="line-height: 0px !important; padding-bottom: 20px !important;" colspan="3"> </td>
</tr>
<tr>
<td colspan="2"><span style="font-weight: bold; font-size: 24px;">Ratings & Awards</span></td>
<td width="33%"> </td>
</tr>
<tr>
<td style="line-height: 0px !important; padding-bottom: 20px !important;" colspan="3"> </td>
</tr>
<tr>
<td style="padding-right: 40px;" colspan="2"><span style="font-size:20px;">★★★★★</span><div style="line-height: 4px;"> </div>
<span style="font-weight: bold;">Morningstar</span>
<div style="line-height: 8px;"> </div>
<span style="font-size: 16px;">This fund has been awarded.</span></td>
<td style="background-image: url('https://i.ibb.co/Jkd3npD/Untitled-1-copy.jpg'); background-repeat: no-repeat; background-size: 189px 117px; width: 189px; height: 117px;" colspan="1"> </td>
</tr>
<tr>
<td style="line-height: 0px !important; padding-bottom: 48px !important;" colspan="3"> </td>
</tr>
</tbody>
</table>
</div>
In this case, the issue was with the emoji 🟢 I used. For some reason Mailchimp didn't allow the table to render correctly.

Syntax error: Unexpected end of file reached. You have an unclosed #if

Below is the code used. Trying to get an image to display ony if the associated field is not empty. Thanks for any help you all can give! Message states the error is on Line 42, column 8.
<table align="center" border="0" cellpadding="0" cellspacing="0" style="width:100%;" width="100%">
<!-- START header -->
<tbody>
<tr>
<td valign="top">
<table align="center" border="0" cellpadding="0" cellspacing="0" style="width:720px;border-top:1px solid #cccccc;border-right:1px solid #cccccc;border-left:1px solid #cccccc;" width="720">
<tbody>
<tr>
<td style="background:#ffffff;width:720px;height:auto; border-bottom: 1px solid #eaeaea; padding-top: 20px; padding-bottom: 20px; padding-left: 27px;" valign="top" width="720">
<font color="#222222">
<img alt="IQAir" id="" name="" src="https://hosting.fyleio.com/40620/public/SanSerif_Desktop_01.jpg?c=1561752071758" style="border: 0px; display: block; width: 300px;" />
</font>
<p style="line-height: 19px; margin-top: 0px; padding-top: 10px;"><span style="font-size:14px;"><span style="font-family:arial,helvetica,sans-serif;"><span style="color:#666666;">Dear ${customer.firstName}, </span></span>
</span><br />
<br />
<br />
<span style="font-size:11.0pt"><span style="font-family:Calibri">It's our pleasure to inform you that your preliminary personalized perfect16 evaluation is almost ready. However, in order to be as accurate as possible we need the following missing information:<br />
<br />
<#if (transaction.custbody117)?has_content></#if><img src=${transaction.custbody135}#elseif<#if (transaction.custbody122)?has_content>img src=${transaction.custbody139}<#if (transaction.custbody118)?has_content>img src=${transaction.custbody140}<#if (transaction.custbody119)?has_content>img src=${transaction.custbody141}<#if (transaction.custbody120)?has_content>img src=${transaction.custbody142}>
<br />
<br />
<span style="font-size:11.0pt"><span style="font-family:Calibri">You may also contact our office for assistance with the missing information so we can continue the analysis of the project. </span></span><br />
<br />
<span style="font-size:11.0pt"><span style="font-family:Calibri"> </span></span><br />
<span style="font-size:11.0pt"><span style="font-family:Calibri">Please feel free to contact me if you have any questions.</span></span><br />
<br />
<br />
</span><br />
</p>
<p style="color: rgb(102, 102, 102); font-family: Arial, Helvetica-Neue, Helvetica, sans-serif; font-size: 8px; margin-bottom: 10px;">
<font color="#222222" face="Arial, Verdana, sans-serif"><span style="font-size: 12px;"> src="https://hosting.fyleio.com/40620/public/SanSerif_Desktop_01.jpg?c=1561752071758" style="background-color: rgb(255, 255, 255); border: 0px currentcolor; vertical-align: middle; width: 64px; height: 16px;" /> </span></font>
<span
style="color:#666666;">
<font face="Arial, Verdana, sans-serif"><span style="font-size: 12px;"><span style="font-size:10px;"><span style="font-family:arial,helvetica,sans-serif;"> <span style="background-color: rgb(255, 255, 255);">©</span> 2020 IQAir North America, Inc. All
rights reserved.</span>
</span>
</span>
</font>
</span>
</p>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td valign="top"> </td>
</tr>
<!-- END content -->
</tbody>
</table>
Seems like you missed closing this tag: <span style="font-size:11.0pt"/>

Need to check the specific cell value from a table in selenium

Need to check the specific cell value from a table in selenium.
As per the GUI view it is the 5th column of 1st Row and I need to keep reading the value of this cell until it changes to some other state from in progress state.Following is the XML:
<html>
<head><style>
BODY
{
font-family: Arial, Helvetica, sans-serif;
font-size: 8pt;
scrollbar-face-color: #666699;
scrollbar-3dlight-color: #c2c8e2;
scrollbar-shadow-color: #c2c8e2;
scrollbar-highlight-color: #666699;
scrollbar-darkshadow-color: #666699;
scrollbar-arrow-color: #e6eef7;
scrollbar-track-color: #e6eef7;
background-color: rgb(255, 255, 255);
}
TD
{
color: #000000;
font-size: 8pt;
}
</style></head>
<body topMargin="0" leftMargin="0" onload="javascript:OnLoad();" onunload="javascript:closeWin();"><div id="divMainTbl" style="width: 1358px; height: 182px; overflow: auto; position: relative;" marginheight="0" marginwidth="0" leftmargin="0" topmargin="0"><form name="frmDSV" id="frmDSV" style="margin-top: 0px; margin-bottom: 0px;" action="/epace/epace-cgi/pacecgi.exe?sessionid=" method="post" target="ifChildEvents"><table width="100%" id="tblQ" border="0" cellSpacing="0" cellPadding="0" nowrap="" xmlns:user="" xmlns:msxsl=""><tbody><tr style="background-color: rgb(241, 241, 241);">
<td noWrap="">
In Progress
</td>
</tr></tbody></table></form></div></body></html>
<DIV id="divMainTbl" style='position:
<TABLE id="tblQ" WIDTH="100&#37" BOR>
<TR>
-- Column <tds
</TR>
<tr style="background-color:#F1F1F1;">
<td class="HU2"> 1 </td>
<td nowrap width="2&#37" height="15" </td>
<td nowrap> Positions </td>
<td nowrap> Data Upload </td>
<td nowrap> Completed </td>
Looks like that's the only td you have. If so it's fairly easy.
//div[#id='divMainTbl']//td
Since the div has an id it easier to start from there and find the ONLY td accordingly.

How to get rid of lines in colspan/rowspan cell of table?

I am trying to recreate something close to this table:
I am getting weird lines, though, with the way that I've gone about trying to do it. How do I get rid of them? Or could someone tell me the easiest way to achieve what is done in the table pictured above? Here is my code:
<!DOCTYPE html>
<html>
<head>
<title>Assignment #4</title>
<style>
table
{
font-family:"Courier New", Arial, Helvetica, sans-serif;
border-collapse:collapse;
margin: auto;
border-bottom-style: double; border-top-style: double;
}
table.border tr {border: 1px solid black; border-left: 0px solid;
border-right: 0px solid;}
th
{
font-size:18px;
font-style: bold;
padding-top:2px;
padding-bottom:2px;
background-color:lightblue;
color:#000000;
}
tr.white td
{
color:#000000;
background-color: #ffffff;
}
td,th
{
font-size:1em;
padding:3px 7px 2px 7px;
text-align: left;
</style>
</head>
<body>
<body>
<h3 style="text-align: center; font-family: courier new;">
<strong>Code-page support in microsoft windows</strong></h3>
<table class="border">
<tr>
<th>Code-Page ID</th>
<th style="border: 1px solid black; text-align: center;">Name</th>
<th colspan="2">ACP OEMCP</th>
</tr
<div>
<tr class="white">
<td style="background-color: lightblue;" rowspan="3">1200
<br/>1250
<br/>1251</td>
<td style="border: 1px solid black;" rowspan="3">Unicode
<br/>Windows 3.1 Eastern European
<br/>Windows 3.1 Cynillic</td>
<td rowspan="3"><br/>X <br/>X</td>
</tr>
<tr class="white">
<td style="border: 1px solid black;"></td>
</tr>
<tr class="white">
<td style="border: 1px solid black;"></td>
</tr>
</div>
<div>
<tr class="white">
<td style="background-color: lightblue;" rowspan="3">437 <br/>708 <br/>709</td>
<td style="border: 1px solid black;" rowspan="3">MS-DOS
<br/>Arabic (ASMO 708)
<br/>Arabic (ASMO 449)</td>
<td><br/></td>
<td colspan="2">X <br/>X <br/>X</td>
</tr>
<tr class="white">
<td style="border: 1px solid black;"></td>
</tr>
<tr class="white">
<td style="border: 1px solid black;"></td>
</tr>
</div>
<div>
<tr class="white">
<td style="background-color: lightblue;">Assignment#4</td>
<td style="border: 1px solid black;">
Mansfield University</td>
<td colspan="2"><center>
<img src="http://mansfield.edu/files/images/Facebook.gif"> </center></td>
</tr>
</div>
</table>
</body>
</html>
First of all the link of the image sample didn't work here for me :(
But if you mean the vertical lines like line1|line2 are your problem, you can use colspan=2. This will result in something like line1 line2.
Example:
<tr>
<td colspan=2>
</td>
<td>
</td>
</tr>
Hope that will help,
Regards,
Otacon
Your code is a mess! You put two "body" and forgot some "}" and ">".
Apart that the problem was the "td's" in blank that you put inside the "tr". Here you have the code:
<!DOCTYPE html>
<html>
<head>
<title>Assignment #4</title>
<style>
table {
font-family:"Courier New", Arial, Helvetica, sans-serif;
border-collapse:collapse;
margin: auto;
border-bottom-style: double; border-top-style: double;
}
table.border tr {
border: 1px solid black;
border-left: 0px solid;
border-right: 0px solid;
}
th{
font-size:18px;
font-style: bold;
padding-top:2px;
padding-bottom:2px;
background-color:lightblue;
color:#000000;
}
tr.white td {
color:#000000;
background-color: #ffffff;
}
td,th{
font-size:1em;
padding:3px 7px 2px 7px;
text-align: left;
}
</style>
</head>
<body>
<h3 style="text-align: center; font-family: courier new;">
<strong>Code-page support in microsoft windows</strong></h3>
<table class="border">
<tr>
<th>Code-Page ID</th>
<th style="border: 1px solid black; text-align: center;">Name</th>
<th colspan="2">ACP OEMCP</th>
</tr>
<tr class="white">
<td style="background-color: lightblue;" rowspan="3">1200
<br/>1250
<br/>1251</td>
<td style="border: 1px solid black;" rowspan="3">Unicode
<br/>Windows 3.1 Eastern European
<br/>Windows 3.1 Cynillic</td>
<td rowspan="3"><br/>X <br/>X</td>
</tr>
<tr class="white">
</tr>
<tr class="white">
</tr>
<tr class="white">
<td style="background-color: lightblue;" rowspan="3">437 <br/>708 <br/>709</td>
<td style="border: 1px solid black;" rowspan="3">MS-DOS
<br/>Arabic (ASMO 708)
<br/>Arabic (ASMO 449)</td>
<td><br/></td>
<td colspan="2">X <br/>X <br/>X</td>
</tr>
<tr class="white">
</tr>
<tr class="white">
</tr>
<tr class="white">
<td style="background-color: lightblue;">Assignment#4</td>
<td style="border: 1px solid black;">
Mansfield University</td>
<td colspan="2"><center>
<img src="http://mansfield.edu/files/images/Facebook.gif"> </center></td>
</tr>
</table>
</body>
</html>
I think that's what you're looking for.
Hope this answer helped you.
Regards,
LGhost