what is the wrong in code?

<file path="catalog/view/theme/*/template/checkout/payment_method.twig">
<operation>
<search><![CDATA[{% for payment_method in payment_methods %}]]></search>
<add position="after"><![CDATA[
{% if payment_method.code == cod %}
{% set  cost= '-'.cod_fee_fee %}
{% endif %}
]]></add>
</operation>
</file>
<file path="catalog/view/theme/*/template/checkout/payment_method.twig">
<operation>
<search><![CDATA[{{ payment_method.title }}]]></search>
<add position="replace"><![CDATA[ {{ payment_method.title }}{{ cost }}]]></add>
</operation>
</file>
Hamdan ShafiqPHP Full Stack DeveloperAsked:
Who is Participating?
 
Leonidas DosasCommented:
Try this:
<file path="catalog/view/theme/*/template/checkout/payment_method.twig">
<operation>
<search><![CDATA[{% for payment_method in payment_methods %}]]></search>
<add position="after"><![CDATA[
{% if payment_method.code == cod %}
{% set  cost= '-'.cod_fee_fee %}
{% endif %}
]]></add>
</operation>

<file path="catalog/view/theme/*/template/checkout/payment_method.twig">
<operation>
<search><![CDATA[{{ payment_method.title }}]]></search>
<add position="replace"><![CDATA[ {{ payment_method.title }}{{ cost }}]]></add>
</operation>
</file>
</file>

Open in new window

As i validate your code i had this error:
The markup in the document following the root element must be well-formed
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.