Änderungen https Andy Müller rückgängig gemacht
This commit is contained in:
@ -103,7 +103,7 @@ function </span>PutLink<span class="kw">(</span>$URL<span class="kw">, </span>$t
|
||||
|
||||
</span>$html <span class="kw">= </span><span class="str">'You can now easily print text mixing different styles: <b>bold</b>, <i>italic</i>,
|
||||
<u>underlined</u>, or <b><i><u>all at once</u></i></b>!<br><br>You can also insert links on
|
||||
text, such as <a href="https://www.fpdf.org">www.fpdf.org</a>, or on an image: click on the logo.'</span><span class="kw">;
|
||||
text, such as <a href="http://www.fpdf.org">www.fpdf.org</a>, or on an image: click on the logo.'</span><span class="kw">;
|
||||
|
||||
</span>$pdf <span class="kw">= new </span>PDF<span class="kw">();
|
||||
</span><span class="cmt">// First page
|
||||
@ -117,7 +117,7 @@ text, such as <a href="https://www.fpdf.org">www.fpdf.org</a>, or on
|
||||
</span><span class="cmt">// Second page
|
||||
</span>$pdf<span class="kw">-></span>AddPage<span class="kw">();
|
||||
</span>$pdf<span class="kw">-></span>SetLink<span class="kw">(</span>$link<span class="kw">);
|
||||
</span>$pdf<span class="kw">-></span>Image<span class="kw">(</span><span class="str">'logo.png'</span><span class="kw">,</span>10<span class="kw">,</span>12<span class="kw">,</span>30<span class="kw">,</span>0<span class="kw">,</span><span class="str">''</span><span class="kw">,</span><span class="str">'https://www.fpdf.org'</span><span class="kw">);
|
||||
</span>$pdf<span class="kw">-></span>Image<span class="kw">(</span><span class="str">'logo.png'</span><span class="kw">,</span>10<span class="kw">,</span>12<span class="kw">,</span>30<span class="kw">,</span>0<span class="kw">,</span><span class="str">''</span><span class="kw">,</span><span class="str">'http://www.fpdf.org'</span><span class="kw">);
|
||||
</span>$pdf<span class="kw">-></span>SetLeftMargin<span class="kw">(</span>45<span class="kw">);
|
||||
</span>$pdf<span class="kw">-></span>SetFontSize<span class="kw">(</span>14<span class="kw">);
|
||||
</span>$pdf<span class="kw">-></span>WriteHTML<span class="kw">(</span>$html<span class="kw">);
|
||||
|
@ -91,7 +91,7 @@ function PutLink($URL, $txt)
|
||||
|
||||
$html = 'You can now easily print text mixing different styles: <b>bold</b>, <i>italic</i>,
|
||||
<u>underlined</u>, or <b><i><u>all at once</u></i></b>!<br><br>You can also insert links on
|
||||
text, such as <a href="https://www.fpdf.org">www.fpdf.org</a>, or on an image: click on the logo.';
|
||||
text, such as <a href="http://www.fpdf.org">www.fpdf.org</a>, or on an image: click on the logo.';
|
||||
|
||||
$pdf = new PDF();
|
||||
// First page
|
||||
@ -105,7 +105,7 @@ $pdf->SetFont('');
|
||||
// Second page
|
||||
$pdf->AddPage();
|
||||
$pdf->SetLink($link);
|
||||
$pdf->Image('logo.png',10,12,30,0,'','https://www.fpdf.org');
|
||||
$pdf->Image('logo.png',10,12,30,0,'','http://www.fpdf.org');
|
||||
$pdf->SetLeftMargin(45);
|
||||
$pdf->SetFontSize(14);
|
||||
$pdf->WriteHTML($html);
|
||||
|
@ -49,7 +49,7 @@ directory of the package: makefont.php. It contains the following function:
|
||||
</dl>
|
||||
The first parameter is the name of the font file. The extension must be either .ttf, .otf or .pfb and
|
||||
determines the font type. If your Type1 font is in ASCII format (.pfa), you can convert it to binary
|
||||
(.pfb) with the help of <a href="https://www.lcdf.org/~eddietwo/type/#t1utils" target="_blank">t1utils</a>.
|
||||
(.pfb) with the help of <a href="http://www.lcdf.org/~eddietwo/type/#t1utils" target="_blank">t1utils</a>.
|
||||
<br>
|
||||
<br>
|
||||
For Type1 fonts, the corresponding .afm file must be present in the same directory.
|
||||
@ -124,7 +124,7 @@ Another way to call MakeFont() is through the command line:
|
||||
<br>
|
||||
<br>
|
||||
Finally, for TrueType and OpenType fonts, you can also generate the files
|
||||
<a href="https://www.fpdf.org/makefont/">online</a> instead of doing it manually.
|
||||
<a href="http://www.fpdf.org/makefont/">online</a> instead of doing it manually.
|
||||
|
||||
<h2>Declaration of the font in the script</h2>
|
||||
The second step is simple. You just need to call the <a href='../doc/addfont.htm'>AddFont()</a> method:
|
||||
@ -140,7 +140,7 @@ had worked with Comic Sans MS Bold (comicbd.ttf), we would have written:
|
||||
</div>
|
||||
|
||||
<h2>Example</h2>
|
||||
Let's now see a complete example. We will use the font <a href="https://www.abstractfonts.com/font/52" target="_blank">Calligrapher</a>.
|
||||
Let's now see a complete example. We will use the font <a href="http://www.abstractfonts.com/font/52" target="_blank">Calligrapher</a>.
|
||||
The first step is the generation of the font files:
|
||||
<div class="source">
|
||||
<pre><code><?php
|
||||
|
Reference in New Issue
Block a user