【问题标题】:Add affiliate tracker code to virtuemart thank you page将会员跟踪器代码添加到美德玛特感谢页面
【发布时间】:2012-11-06 22:37:48
【问题描述】:

我想使用 VirtueMart 向我的基于 Joomla 的网站添加会员跟踪代码。他们告诉我在感谢页面上添加代码,但我无法弄清楚。 VirtueMart版本为2.0.12,代码为

<script src="http://network.clickbanner.gr/i_sale_third/10566/SALE_AMOUNT/TRANSACTION_ID
/OPTIONAL_INFORMATION&sale_status=P"></script>
<noscript><img src="http://network.clickbanner.gr/i_track_sale/10566/SALE_AMOUNT/TRANSACTION_ID
/OPTIONAL_INFORMATION&sale_status=P"></noscript>

我必须将SALE_AMOUNT 替换为不含税的订单价格,并将transaction_id 替换为订单ID。任何想法如何实现这一目标?

【问题讨论】:

    标签: joomla virtuemart affiliate


    【解决方案1】:

    解决方案:

    感谢页面的输出可以在/plugins/vmpayment/standard/standard.php(标准支付方式)或/plugins/vmpayment/paypal/paypal.php中编辑。在plgVmConfirmedOrder($cart, $order) 函数中找到$html 变量,并在$html .= '&lt;/table&gt;' . "\n"; 行(第135 行)之后添加您想要的代码。就我而言,代码是:

    $html .= '<script src="http://network.clickbanner.gr/i_sale_third/10566/'.$order['details']['BT']->order_subtotal.'/'.$order['details']['BT']->order_number.'
    /OPTIONAL_INFORMATION&sale_status=P"></script><noscript><img src="http://network.clickbanner.gr/i_track_sale/10566/'.$order['details']['BT']->order_subtotal.'/'.$order['details']['BT']->order_number.'/OPTIONAL_INFORMATION&sale_status=P"></noscript>';
    

    【讨论】:

      【解决方案2】:

      你可以做到这一点,

      First the order confirmation page of VM2.x is order_done.php 
      the file you can find in the path : components/com_virtuemart/view/cart/tmpl/order_done.php
      

      第二件事。

      订单表#__virtuemart_orders中存储在VM中的订单

      with order id you can find all the amounts. with tax without tax etc.
      (order_number,order_pass,order_total,order_subtotal,order_tax)
      

      【讨论】:

      • 加在那里合适吗?我看到它调用 /plugins/vmpayment/standard/standard.php 中的 $html。我尝试在 $html.='' 之前的 $html 中添加脚本代码,但随后页面中出现 500 错误。
      • Vm 感谢页面是 order_done.php 如果你想把东西放在任何其他地方,比如运输或付款部分,那么你可以在插件路径中找到这些
      • 我终于在standard.php文件中做到了!输出显示在感谢页面上!当我回家时,我会在这里发布解决方案。感谢您的回答。
      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-03-12
      • 1970-01-01
      • 2021-03-25
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多