WordPress.org

Ready to get started?Download WordPress

Forums

PrestaShop Integration
Support for smarty template variables in header and footer (4 posts)

  1. madn3ss75
    Member
    Posted 1 year ago #

    Hello,
    i suggest you to add 2 lines of code in the init() function of the PrestaShopIntegration_FrontController class:
    after:
    parent::init();
    add:

    parent::initHeader();
    parent::initFooter();
    parent::initContent();

    In that way the smarty variables initialized in prestashop header, footer and content will be available using $prestashop_integration->getTemplateVars() (for example logo_url, logo_image_height, logo_image_width and so on...).

    It will be wonderful if the widget could render a single prestashop template (like header.tpl or footer.tpl).

    Thanks for the great work.

    http://wordpress.org/extend/plugins/prestashop-integration/

  2. aytechnet
    Member
    Plugin Author

    Posted 1 year ago #

    Hello madn3ss75,

    I will add some calls to PrestaShop internal, but the plugin is still compatible with PrestaShop 1.4 and must be kept compatible.

    For calling specific PrestaShop template, you generally need to add more variables according to the page examined (produts, categories, a specific product, ...). For header.tpl and footer.tpl, you already have the PrestaShop Integration Hook widget, which will be used to put theses templates.

    Thanks, do not forget to give a review to the module.

    Fran├žois.

  3. madn3ss75
    Member
    Posted 1 year ago #

    Ops, 1.4 compatibility was not one of my goals. I'm sorry.

    Regarding the hooks, they are different from the (customizable) header and footer template files.
    I'm not so good at prestashop (maybe due to lack of documentation), but I believe that you could render a single template file using some simple methods from the FrontController (such as setTemplate() and display()).

    Thanks.

    Giuseppe

  4. aytechnet
    Member
    Plugin Author

    Posted 1 year ago #

    Ok, for your need a new widget could be made for integrating a hook directly so that the blog header and footer may be different from the shop itself (for example).

    Fran├žois.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic