简体   繁体   English

twif到tpl opencart 2.3.0.2

[英]twif to tpl opencart 2.3.0.2

Hi I have a module that is for 2.3.0.2 but it has some code written for twig and it is not working for 2.3.0.2, can any one help to get this code back to tpl. 嗨,我有一个用于2.3.0.2的模块,但是它有一些为twig编写的代码,而对于2.3.0.2则不起作用,任何人都可以帮助将该代码恢复为tpl。

product['model']<a style="cursor:pointer" onclick="refudt(this)"  data- 
type="model" data-pid="product['product_id']"> (?)</a>

{{ product.price }} <a style="cursor:pointer" onclick="refudt(this)"  data- 
type="price" data-pid="{{ product.product_id }}"> (?)</a>

 {{ product.name }}<a style="cursor:pointer" onclick="refudt(this)"  data- 
 type="name" data-pid="{{ product.product_id }}"> (?)</a></a>

{{ product.quantity }}<a style="cursor:pointer" onclick="refudt(this)"  
data-type="quantity" data-pid="{{ product.product_id }}"> (?)</a>

{{ total.text }}<a style="cursor:pointer" onclick="refudt(this)"  data- 
type="total" data-pid="{{total.order_total_id}}"> (?)</a>

this part not a TWIG and not php (tpl) 这部分不是TWIG而不是php(tpl)

product['model']<a style="cursor:pointer" onclick="refudt(this)"  data- 
    type="model" data-pid="product['product_id']"> (?)</a>

the last part should look like this: 最后一部分应如下所示:

<?php echo $product['price']; ?> <a style="cursor:pointer" onclick="refudt(this)"  data- 
type="price" data-pid="<?php echo $product['product_id']; ?>"> (?)</a>

 <?php echo $product['name']; ?><a style="cursor:pointer" onclick="refudt(this)"  data- 
 type="name" data-pid="<?php echo $product['product_id']; ?>"> (?)</a></a>

<?php echo $product['quantity']; ?><a style="cursor:pointer" onclick="refudt(this)"  
data-type="quantity" data-pid="<?php echo $product['product_id']; ?>"> (?)</a>

<?php echo $total['text']; ?><a style="cursor:pointer" onclick="refudt(this)"  data- 
type="total" data-pid="<?php echo $total['order_total_id']; ?>"> (?)</a>

You should understand I hope... 你应该明白我希望...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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