Forum Bugs

Bold text will not adjust in size (inline styles)

elvanto
Hi guys,

I am having an issue where bold text does not change in size when adjusted. See the attached PDF file. Both paragraphs have a font-size applied within a span. But the one that also contains a <strong> fails.

Here is my HTML.

<div class="page">

<p><span style="font-size:24px"><strong>Bold Text</strong></span></p>

<p><span style="font-size:24px">Normal Text</span></p>

</div>


And here's my full styles.

* {
	font-family: "Times New Roman";
	font-size: 10pt;
}
@page {
	size: A4 portrait;
	margin: 0cm 2.7cm 0cm 2.7cm;
 }
.page {
	page-break-before: always;
}
.colspan2 { table-column-span: 2; }
.colspan3 { table-column-span: 3; }
.colspan4 { table-column-span: 4; }
.colspan5 { table-column-span: 5; }
.colspan6 { table-column-span: 6; }
.colspan7 { table-column-span: 7; }
.colspan8 { table-column-span: 8; }
.colspan9 { table-column-span: 9; }
.colspan10 { table-column-span: 10; }
.colspan11 { table-column-span: 11; }
.colspan12 { table-column-span: 12; }
.colspan13 { table-column-span: 13; }
.colspan14 { table-column-span: 14; }
.colspan15 { table-column-span: 15; }
.colspan16 { table-column-span: 16; }
.colspan17 { table-column-span: 17; }
.colspan18 { table-column-span: 18; }
.colspan19 { table-column-span: 19; }
.colspan20 { table-column-span: 20; }
.rowspan2 { table-row-span: 2; }
.rowspan3 { table-row-span: 3; }
.rowspan4 { table-row-span: 4; }
.rowspan5 { table-row-span: 5; }
.rowspan6 { table-row-span: 6; }
.rowspan7 { table-row-span: 7; }
.rowspan8 { table-row-span: 8; }
.rowspan9 { table-row-span: 9; }
.rowspan10 { table-row-span: 10; }
.rowspan11 { table-row-span: 11; }
.rowspan12 { table-row-span: 12; }
.rowspan13 { table-row-span: 13; }
.rowspan14 { table-row-span: 14; }
.rowspan15 { table-row-span: 15; }
.rowspan16 { table-row-span: 16; }
.rowspan17 { table-row-span: 17; }
.rowspan18 { table-row-span: 18; }
.rowspan19 { table-row-span: 19; }
.rowspan20 { table-row-span: 20; }


Any ideas?
  1. Example.pdf27.7 kB
    Example printed from my local dev
mikeday
Hmm, there must be more to it than that. Can you attach a small HTML file that demonstrates the problem? The snippet you have attached works fine.
elvanto
Thanks Mike. Attached is my PHP code. I've tested it on my local and it's experiencing the same issue. Not sure what I am doing wrong. The prince.php file I downloaded off the website.

Any ideas?
  1. Archive.zip6.5 kB
mikeday
Oops, I missed this rule in the style that you posted:
* {
        font-family: "Times New Roman";
        font-size: 10pt;
}

This will make all elements 10pt unless explicitly overridden. You don't want to do this. Apply it to <body> or a wrapper <div> instead, and let the font-size inherit.
elvanto
Ah thanks Mike! Don't know how I didn't think of that. I am a bit of a * n00b obviously :) Thanks again for the amazing support