File: aliasnbpages.htm

package info (click to toggle)
php-fpdf 3%3A1.8.4.dfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 772 kB
  • sloc: php: 3,254; makefile: 45; sh: 5
file content (44 lines) | stat: -rw-r--r-- 1,239 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>AliasNbPages</title>
<link type="text/css" rel="stylesheet" href="../fpdf.css">
</head>
<body>
<h1>AliasNbPages</h1>
<code>AliasNbPages([<b>string</b> alias])</code>
<h2>Descrizione</h2>
Definisce un alias per il numero totale di pagine. Sar sostituito alla chiusura del documento.
<h2>Parametri</h2>
<dl class="param">
<dt><code>alias</code></dt>
<dd>
L'alias. Valore di default: <code>{nb}</code>.
</dd>
</dl>
<h2>Esempio</h2>
<div class="doc-source">
<pre><code>class PDF extends FPDF
{
function Footer()
{
    // Va a 1.5 cm dal fondo della pagina
    $this-&gt;SetY(-15);
    // Seleziona Arial corsivo 8
    $this-&gt;SetFont('Arial','I',8);
    // Stampa il numero di pagina corrente e totale
    $this-&gt;Cell(0,10,'Page '.$this-&gt;PageNo().'/{nb}',0,0,'C');
}
}

$pdf = new PDF();
$pdf-&gt;AliasNbPages();</code></pre>
</div>
<h2>Vedi anche</h2>
<a href="pageno.htm">PageNo</a>,
<a href="footer.htm">Footer</a>
<hr style="margin-top:1.5em">
<div style="text-align:center"><a href="index.htm">Indice</a></div>
</body>
</html>