简体   繁体   中英

How can I write this in twig

I have a line of php redirect code and I want to write it in twig, as I am using opencart 3. Can anyone kindly let me know how to do it? The code is as below.

<?php $this->redirect($this->url->link('product/category', 'path=2')); ?>

here you code looks in twig

{% set this.redirect(this.url.link('product/category', 'path=2')) = 'undefined' %}

hope this might help you

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM