Jump to content

Place viewed products in the center column


Recommended Posts

Hi, I am new to prestashop, its a realy great product dough!

 

im creating a sings column webshop. and i want the "viewed product" module in the center column (i disabled the left and right column in "live edit" mode). When i want to drag the module the a red rectangle appears. wicht files do i have to modify to realise what i want.

 

See picture!!

 

Thanks

post-347585-0-04955200-1333963659_thumb.png

Link to comment
Share on other sites

Well, firstly that module is not designed to work in that position. You can open up blockviewed.php' and change the hooks.

 

Find:

 

if (!parent::install()
  OR !$this->registerHook('leftColumn')
  OR !$this->registerHook('header')
  OR !Configuration::updateValue('PRODUCTS_VIEWED_NBR', 2))
  return false;
 return true;

 

And change 'leftcolumn' to 'home'

 

Also:

 

function hookLeftColumn($params)
{
 return $this->hookRightColumn($params);
}
function hookHeader($params)

 

And change 'leftcolumn' again.

 

Uninstall the module before you do this then re-install. However, there is no guarantee the module will look right in this new position or even sit correctly as, like I said, it wasn't designed to work there so you may have to mess around with it further.

  • Like 1
Link to comment
Share on other sites

  • 1 month later...

Well, firstly that module is not designed to work in that position. You can open up blockviewed.php' and change the hooks.

 

Find:

 

if (!parent::install()
  OR !$this->registerHook('leftColumn')
  OR !$this->registerHook('header')
  OR !Configuration::updateValue('PRODUCTS_VIEWED_NBR', 2))
  return false;
 return true;

 

And change 'leftcolumn' to 'home'

 

Also:

 

function hookLeftColumn($params)
{
 return $this->hookRightColumn($params);
}
function hookHeader($params)

 

And change 'leftcolumn' again.

 

Uninstall the module before you do this then re-install. However, there is no guarantee the module will look right in this new position or even sit correctly as, like I said, it wasn't designed to work there so you may have to mess around with it further.

your advice worked great but it only works if some products are already in cookie, if i open same page in different browser it wont work ..... plzz help..

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...