Elxis CMS Forum

Support => FAQs => Topic started by: owl on August 26, 2008, 15:37:37

Title: HowTo: Change RTF- and PDF-Header-Image and Fonts/Fontcolor
Post by: owl on August 26, 2008, 15:37:37
includes/rtf.php
--> "fonts":
Code: [Select]
$arial14 = new Font(14, 'Arial', '[color=red]#1060AE[/color]');
--> "headers":
Code: [Select]
$header->addImage($mosConfig_absolute_path.'/templates/YOURTEMPLATE/images/logo.png', $null);


includes/pdf.php
--> "header_logo":
Code: [Select]
  //if (file_exists('../../../templates/YOURTEMPLATE/images/logo.png')) {
   [color=red] $header_logo = '../../../templates/YOURTEMPLATE/images/logo.png';[/color]
  /*} else {
    $header_logo = PDF_HEADER_LOGO;
  }*/
(file_exists: in my case this solution didn't work correct, so I commented the "file_exists" stuff out (and hope, that you know, what this code does, and where your template is located))



includes/tcpdf/tcpdf.php
--> "header title":
   
Code: [Select]
// header title
$this->SetTextColor[color=red]('16', '96', '174')[/color]; //added by I.Sannos
         

Best regards,
Sandra
Title: Re: HowTo: Change RTF- and PDF-Header-Image and Fonts/Fontcolor
Post by: owl on August 27, 2008, 10:36:41
Changing FOOTER-Title etc. ;-)

includes/pdf.php
--> "footer":
Code: [Select]
$foot = &$rtf->addFooter();
$ver = ''; <<-- Footer-Text
$foot->writeText($ver, new Font(8, 'Verdana'), $parFormat);

includes/tcpdf/tcpdf.php
--> "footer title":
Code: [Select]
$this->SetXY($this->original_lMargin, $footer_y);

$this->Cell(0, $footer_height, PDF_FOOTER_TITLE , 'B', 0, 'C'); //added by I.Sannos <<-- "Footer"
//Print page number
$this->Cell(0, $footer_height, $this->l['w_page']." ".$this->PageNo().' / {nb}', 'T', 0, 'R');
      
      
includes/tcpdf/config/tcpdf_config.php
--> "footer title":
Code: [Select]
/**
 * footer title
 */
 define ("PDF_FOOTER_TITLE", "YOUR INCREDIBLE TITLE - http://www.yoursite.com/");