Jump to content

Facebook Like Box Block in Footer


nubekids

Recommended Posts

hi, 

 

Edit module file blockfacebook.php

	public function install()
	{
		return parent::install() &&
			Configuration::updateValue('blockfacebook_url', 'https://www.facebook.com/prestashop') &&
			$this->registerHook('displayHome') &&
			$this->registerHook('displayHeader');
	}

By this one

	public function install()
	{
		return parent::install() &&
			Configuration::updateValue('blockfacebook_url', 'https://www.facebook.com/prestashop') &&
			$this->registerHook('displayHome') &&
			$this->registerHook('displayFooter') &&
			$this->registerHook('displayHeader');
	}

Then, Copy this code

	public function hookDisplayLeftColumn()
	{
		if ($this->page_name !== 'index')
			$this->_assignMedia();
		return $this->hookDisplayHome();
	}

Modified by it

	public function hookDisplayFooter()
	{
		if ($this->page_name !== 'index')
			$this->_assignMedia();
		return $this->hookDisplayHome();
	}

Insert this code just before

	protected function _assignMedia()
	{
		$this->context->controller->addCss(($this->_path).'css/blockfacebook.css');
		$this->context->controller->addJS(($this->_path).'blockfacebook.js');
	}
There you go
 
Then in your back office, graft the module in the footer
 
 
Sorry for my english, i translated with google
 
Good continuation
  • Like 1
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...