Php 如何从HTML模板中删除标题?

Php 如何从HTML模板中删除标题?,php,prestashop,smarty,Php,Prestashop,Smarty,我试图修改一个prestashop模块,这个类管理pdf的创建 类HTMLTemplateQuotationPdf扩展HTMLTemplate { 公共购物车; 公开报价:$quote; 公共环境; 私人股本为1.5亿美元; 公共函数构造($QUOTE$smarty) { $this->module=module::getInstanceByName('opartdevis'); $this->quote=$quote; $this->smarty=$smarty; $this->context

我试图修改一个prestashop模块,这个类管理pdf的创建

类HTMLTemplateQuotationPdf扩展HTMLTemplate
{
公共购物车;
公开报价:$quote;
公共环境;
私人股本为1.5亿美元;
公共函数构造($QUOTE$smarty)
{
$this->module=module::getInstanceByName('opartdevis');
$this->quote=$quote;
$this->smarty=$smarty;
$this->context=context::getContext();
$this->cart=新购物车($quote->id\u cart);
$this->shop=newshop(Context::getContext()->shop->id);
$this->context->language=新语言($this->cart->id\u lang);
$this->isseen=Tools::version\u compare('1.7','>=')?true:false;
$this->context->currency=新货币((int)$this->cart->id\u currency);
}
公共函数getContent()
{
$max_prod_page=((int)配置::get('opartdesign_prod_page')==0)?13:(int)配置::get('opartdesign_prod_page');
$max_prod_first_page=((int)配置::get('opartdesign_prod_first')==0)?8:(int)配置::get('opartdesign_prod_first');
$priceDisplay=((int)配置::get('PS_TAX')==0)?1:Product::getTaxCalculationMethod((int)$this->cart->id_customer);
$customized_data=Product::GetAllCustomizedData($this->cart->id);
$this->smarty->assign(数组)(
“报价单”=>$this->quote,
“购物车”=>$this->cart,
“CustomizedData”=>$customized_数据,
'message\u visible'=>explode(PHP\u EOL,$this->quote->message\u visible),
'validity'=>(int)配置::get('opartdesign_validity'),
“priceDisplay”=>$priceDisplay,
'use_TAX'=>(int)配置::get('PS_TAX'),
'validationText'=>explode(PHP_EOL,Configuration::get('opartdesign_VALIDATION_TEXT',$this->context->language->id)),
'goodforagrementText'=>explode(PHP_EOL,Configuration::get('opartdesign_AGREMENT_TEXT',$this->context->language->id)),
“maxProdFirstPage”=>$max_prod_first_page,
'maxProdPage'=>$max\u prod\u page,
'pdf_shopping_cart_template'=>$this->opartdeveliangetTemplate('shopping-cart-product-line'),
“税务详情”=>$this->quote->getDetailsTax($this->cart),
));
返回$this->smarty->fetch($this->opartdesigngettemplate('quote'));
}
公共函数getHeader()
{
}
公共函数getFooter()
{
$shop_address=$this->getShopAddress();
$this->smarty->assign(数组)(
“在您的账户中可用”=>$this->available\u在您的账户中可用,
“店铺地址”=>$shop\u地址,
'shop\u fax'=>Configuration::get('PS\u shop\u fax',null,null,(int)$this->cart->id\u shop),
'shop\u phone'=>Configuration::get('PS\u shop\u phone',null,null,(int)$this->cart->id\u shop),
'shop\u details'=>Configuration::get('PS\u shop\u details',null,null,(int)$this->cart->id\u shop),
'free_text'=>Configuration::get('PS_INVOICE_free_text',(int)Context::getContext()->语言->id,null,(int)$this->cart->id_shop)
));
返回$this->smarty->fetch($this->opartdesigngetTemplate('footer'));
}
公共函数getFilename()
{
返回$this->module->l('quote','htmltemplatequotationpdf')。“'.$this->quote->id..pdf';
}
公共函数getBulkFilename()
{
返回$this->module->l('quote','htmltemplatequotationpdf')。.pdf';
}
/**
*如果模板不在主题目录中,它将返回默认模板
*在opartdesign/views/templates/front/pdf/目录中
*
*@param$template_name
*
*@返回字符串
*/
受保护的函数opartDevisionGetTemplate($template\u name)
{
$template=false;
$default_template=rtrim($PS_MODULE_DIR_,DIRECTORY_SEPARATOR)。DIRECTORY_SEPARATOR.'opartdesign/views/templates/front/pdf'。DIRECTORY_SEPARATOR.$template_name.'.tpl';
如果($this->isSeven){
$overrided_template=\u PS_ALL_THEMES_DIR.$this->shop->theme->getName().DIRECTORY_SEPARATOR.'modules/opartdesign/views/templates/front/pdf'。DIRECTORY_SEPARATOR.$template_name..tpl';
}否则{
$overrided_template=_PS_ALL_THEMES_DIR.$this->shop->getTheme().DIRECTORY_SEPARATOR.'modules/opartdesign/views/templates/front/pdf'.DIRECTORY_SEPARATOR.$template_name..tpl';
}
如果(文件_存在($overrided_template)){
$template=$overrided\u模板;
}elseif(文件存在($default\u模板)){
$template=$default\u模板;
}
返回$template;
}
}
我想删除标题或至少减少大小。

问题是当我试图删除函数getHeader()时,我选择了默认的头。 当我删除get Header()的内容时,Header仍然会占据它的位置,并显示大量的白色内容

我该怎么办? 我不太习惯PHP


提前感谢

在生成的HTML中,标题仍然存在。如果要完全删除标题,可以从管理页面或通过删除header.tpl的内容来完成