Bonjour à tous, j'utilise une partie du script du site pour numéroter les pages: ça fonctionne.
J'utilise le script pour créer un tableau: ça fonctionne.
Quand j'essaie de mettre les deux sur la même page je perd la numérotation:

Code : Sélectionner tout - Visualiser dans une fenêtre à part
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
 
<?php
require('../../../fpdf.php');
include("../../../phpToPDF.php");
if(isset($_POST['num_visite']))      $num_visite=$_POST['num_visite'];
else      $num_visite = $_GET['num_visite'];
//Connexion à la base
mysql_connect('localhost','root','');
mysql_select_db('mabase');
 
//----Numérotation de pages---------------------------------------------------------
class PDF extends FPDF
{
 
//Pied de page
function Footer()
{
    //Positionnement à 1,5 cm du bas
    $this->SetY(-15);
    //Police Arial italique 8
    $this->SetFont('Arial','I',8);
    //Numéro de page
    $this->Cell(0,10,'Page '.$this->PageNo().'/{nb}',0,0,'C');
}
}
 
//Instanciation de la classe dérivée
$pdf=new PDF();
$pdf->AliasNbPages();
$pdf->AddPage();
$pdf->SetFont('Times','',12);
 
//---Insertion tableau------------------------------------------
$pdf=new phpToPDF();
 
$pdf->AddPage();
$pdf->SetFont('Arial','B',16);
 
// Définition des propriétés du tableau.
$proprietesTableau = array(
	'TB_ALIGN' => 'L',
	'L_MARGIN' => 15,
	'BRD_COLOR' => array(0,92,177),
	'BRD_SIZE' => '0.3',
	);
 
// Définition des propriétés du header du tableau.	
$proprieteHeader = array(
	'T_COLOR' => array(10,10,10),
	'T_SIZE' => 12,
	'T_FONT' => 'Arial',
	'T_ALIGN' => 'C',
	'V_ALIGN' => 'T',
	'T_TYPE' => 'B',
	'LN_SIZE' => 7,
	'BG_COLOR_COL0' => array(245, 245, 150),
	'BG_COLOR' => array(245, 245, 150),
	'BRD_COLOR' => array(0,92,177),
	'BRD_SIZE' => 0.2,
	'BRD_TYPE' => '1',
	'BRD_TYPE_NEW_PAGE' => '',
	);
 
// Contenu du header du tableau.	
$contenuHeader = array(
	50, 100,
	"Première colonne", "année N-1",
	);
 
// Définition des propriétés du reste du contenu du tableau.	
$proprieteContenu = array(
	'T_COLOR' => array(0,0,0),
	'T_SIZE' => 10,
	'T_FONT' => 'Arial',
	'T_ALIGN_COL0' => 'L',
	'T_ALIGN' => 'R',
	'V_ALIGN' => 'M',
	'T_TYPE' => '',
	'LN_SIZE' => 6,
	'BG_COLOR_COL0' => array(245, 245, 150),
	'BG_COLOR' => array(255,255,255),
	'BRD_COLOR' => array(0,92,177),
	'BRD_SIZE' => 0.1,
	'BRD_TYPE' => '1',
	'BRD_TYPE_NEW_PAGE' => '',
	);	
 
// Contenu du tableau.	
$contenuTableau = array(
	"champ 1", 1,
	"champ 2", 3,
	"champ 3", 5,
	"champ 4", 7,
	"champ 5", 1,
	"champ 6", 3,
	"champ 7", 5,
	"champ 8", 7,
	);
 
// Ensuite, le header du tableau (propriétés et données) puis le contenu (propriétés et données)
$pdf->drawTableau($pdf, $proprietesTableau, $proprieteHeader, $contenuHeader, $proprieteContenu, $contenuTableau);
 
mysql_close(); 
$pdf->Output();
 
?>
Merci d'avance pour votre aide.