Jump to content

pre footer


Recommended Posts

A la demande d'Ariane, voici donc la solutions pour greffer le blockreinsurance sur la homepage de votre site :

 

1. Ouvrez le fichier /modules/blockreinsurance.php, et repérez ce code :

	public function hookFooter($params)
	{
		$this->context->controller->addCSS($this->_path.'style.css', 'all');
		if (!$this->isCached('blockreinsurance.tpl', $this->getCacheId()))
		{
			$infos = $this->getListContent($this->context->language->id);
			$this->context->smarty->assign(array('infos' => $infos, 'nbblocks' => count($infos)));
		}
		return $this->display(__FILE__, 'blockreinsurance.tpl', $this->getCacheId());
	}

2. copiez le et insérez le juste en dessous, vous devez obtenir ceci :

	}

	public function hookFooter($params)
	{
		$this->context->controller->addCSS($this->_path.'style.css', 'all');
		if (!$this->isCached('blockreinsurance.tpl', $this->getCacheId()))
		{
			$infos = $this->getListContent($this->context->language->id);
			$this->context->smarty->assign(array('infos' => $infos, 'nbblocks' => count($infos)));
		}
		return $this->display(__FILE__, 'blockreinsurance.tpl', $this->getCacheId());
	}
	
		public function hookFooter($params)
	{
		$this->context->controller->addCSS($this->_path.'style.css', 'all');
		if (!$this->isCached('blockreinsurance.tpl', $this->getCacheId()))
		{
			$infos = $this->getListContent($this->context->language->id);
			$this->context->smarty->assign(array('infos' => $infos, 'nbblocks' => count($infos)));
		}
		return $this->display(__FILE__, 'blockreinsurance.tpl', $this->getCacheId());
	}

	public function installFixtures()

3. modifiez le hook sur le code que vous venez de copier. vous vedrez avoir ceci :

	public function hookFooter($params)
	{
		$this->context->controller->addCSS($this->_path.'style.css', 'all');
		if (!$this->isCached('blockreinsurance.tpl', $this->getCacheId()))
		{
			$infos = $this->getListContent($this->context->language->id);
			$this->context->smarty->assign(array('infos' => $infos, 'nbblocks' => count($infos)));
		}
		return $this->display(__FILE__, 'blockreinsurance.tpl', $this->getCacheId());
	}
	
		public function hookHome($params)
	{
		$this->context->controller->addCSS($this->_path.'style.css', 'all');
		if (!$this->isCached('blockreinsurance.tpl', $this->getCacheId()))
		{
			$infos = $this->getListContent($this->context->language->id);
			$this->context->smarty->assign(array('infos' => $infos, 'nbblocks' => count($infos)));
		}
		return $this->display(__FILE__, 'blockreinsurance.tpl', $this->getCacheId());
	}

4 Sauvegardez et transférez le.

5 Connectez vous a votre admin->modules->positions->greffer un module

6. trouver votre module blockreinsurance 

7 Greffer sur le hook Home.

 

simple et efficace.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...