Hallo,
ich habe folgendes Problem...
in meinem individuell gestalteten Rechnungsformular "invoicepdf.tpl" ist offensichtlich ein Fehler. Ich kann mir aber nicht erklären, wo dort dieser Fehler liegen soll... Wenn ich manuell, also mit bestätigen des Buttons im Adminbereich, eine pdf Rechnung generiere funktioniert das einwandfrei und das Ergebnis ist so wie ich es haben möchte. Der Fehler tritt auf, wenn der cron job drüber lauft, dann werden 2 Rechnungen generiert und eine versendet. Wenn ich den cronjob in debug modus laufen lasse kommt diese Fehlermeldung:
root@s1intern1:/srv/webs/gulix/whmcs# php -q /srv/webs/gulix/whmcs/admin/cron.php debug
Starting (Time: 0.13 Memory: 15.47)
Starting Generating Invoices (Time: 0 Memory: 15.47)
Invoicing Loop Domain ID 8 - 1 of 18 (Time: 0 Memory: 15.86)
Invoicing Loop Domain ID 10 - 2 of 18 (Time: 0 Memory: 15.86)
Invoicing Loop Domain ID 11 - 3 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 28 - 4 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 26 - 5 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 27 - 6 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 25 - 7 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 29 - 8 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 13 - 9 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 12 - 10 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 35 - 11 of 18 (Time: 0 Memory: 15.87)
Invoicing Loop Domain ID 7 - 12 of 18 (Time: 0 Memory: 15.88)
Invoicing Loop Domain ID 36 - 13 of 18 (Time: 0 Memory: 15.88)
Invoicing Loop Domain ID 6 - 14 of 18 (Time: 0 Memory: 15.88)
Invoicing Loop Domain ID 5 - 15 of 18 (Time: 0 Memory: 15.88)
Invoicing Loop Domain ID 70 - 16 of 18 (Time: 0 Memory: 15.88)
Invoicing Loop Domain ID 69 - 17 of 18 (Time: 0 Memory: 15.88)
Invoicing Loop Domain ID 71 - 18 of 18 (Time: 0 Memory: 15.88)
- 0 Invoices Created (Time: 0 Memory: 15.88)
Starting Applying Late Fees (Time: 0 Memory: 15.88)
- Late Invoice Fees added to 0 Invoices (Time: 0 Memory: 15.88)
Starting Processing Credit Card Charges (Time: 0 Memory: 15.88)
- Credit Card Payments Processed (0 Captured, 0 Failed) (Time: 0 Memory: 15.88)
Starting Processing Invoice Reminder Notices (Time: 0 Memory: 15.88)
PHP Warning: Illegal string offset 'emailquote' in /srv/webs/gulix/whmcs/includes/functions.php on line 0
- Sent First Notice to User Ralf Gulich (Time: 0.32 Memory: 26.77)
PHP Fatal error: Cannot redeclare printFooter() (previously declared in /srv/webs/gulix/whmcs/templates/default/invoicepdf.tpl:220) in /srv/webs/gulix/whmcs/templates/default/invoicepdf.tpl on line 266
Alles anzeigen
... besagt also, dass in der Zeile 220 bis 266 ein fehler liegen soll bzw.... aber ich erkenne diesen nicht. Vielleicht sehe auch den Wald vor lauter Bäumen nicht. Der WHMCS Support hat mir sinngemäß für diese Problem geantwortet, dass ich den code zwischen zeile 220 und 266 raus nehmen soll und dann jemand fragen soll der sich damit auskennt. Also haben die den Fehler auch nicht entdeckt.
Hier der Code-Block von 220 bis 266:
function printFooter($pdf) {
// Faltmarke
$pdf->SetDrawColor(60,60,60);
$pdf->SetLineWidth(0.2);
$pdf->Line(5,100.5,10,100.5);
// Lochmarke
$pdf->SetDrawColor(60,60,60);
$pdf->SetLineWidth(0.2);
$pdf->Line(5,148.5,10,148.5);
$pdf->SetFont(NULL,'B',7);
$pdf->SetTextColor(0,0,0);
$pdf->SetY(-30);
$pdf->Cell(30,0,'Anschrift',0,0,'L');
$pdf->SetX(70);
$pdf->Cell(50,0,'Bankverbindung',0,0,'L');
$pdf->SetX(140);
$pdf->Cell(40,0,'Kontakt',0,0,'L');
$pdf->SetAutoPageBreak(true,10);
// horizontale Linie
$pdf->Ln(1);
$pdf->SetDrawColor(60,60,60);
$pdf->SetLineWidth(0.2);
$pdf->Line($pdf->GetX(),$pdf->GetY()-4,190,$pdf->GetY()-4);
$pdf->Ln(1);
$pdf->SetFont(NULL,'',7);
$Footer_Anfang_Y = $pdf->GetY()+1;
$pdf->SetY($Footer_Anfang_Y);
$pdf->MultiCell(30,6,"gulix-web4you\nInhaber: Ralf Gulich\nAm Eichelsberg 9\n56154 Boppard\nUstIDNr: DE285216386\n",0,'L',0);
$pdf->SetY($Footer_Anfang_Y);
$pdf->SetX(70);
$pdf->MultiCell(60,6,"Kreissparkasse Rhein-Hunsrück\nKonto: 8805475 BLZ: 560 517 90\nIBAN: DE53560517900008805475\nBIC: MALADE51SIM\nPayPal: paypal@gulich-net.de\n",0,'L',0);
$pdf->SetY($Footer_Anfang_Y);
$pdf->SetX(140);
$pdf->MultiCell(40,6,"Telefon: +49 6745 18380-0\nTelefax: +49 6745 18380-39\nE-Mail: info@gulix.de\n",0,'L',0);
$pdf->SetY($Footer_Anfang_Y+11);
$pdf->SetX(185);
$pdf->MultiCell(18,6,$pdf->getAliasNumPage() . " / " . $pdf->getAliasNbPages(),0,'R',0);
}
Alles anzeigen
Wird natürlich hiermit aufgerufen zum Schluß
Entdeckt jemand den Fehler oder hat einer einen Tipp, was da schief läuft???
Vielen dank im Voraus.