简体   繁体   English

错误代码:21002 货币:使用 codeigniter 缺少必需的参数(CCAvenue)

[英]Error Code: 21002 currency: Required parameter missing (CCAvenue) using codeigniter

I have installed the plugin and set it up successfully, but when I tried to pay with this, it's showing error:我已经安装了插件并成功设置了它,但是当我尝试用它付款时,它显示错误:

"Error Code: 21002 Invalid Currency Parameter." “错误代码:21002 无效的货币参数。”

After code review I came to know that query string, the currency parameter getting changed to " ¤cy=INR " as " ¤ " is getting executed as html special character.在代码审查之后,我开始知道查询字符串, currency参数被更改为“ ¤cy=INR ”,因为“ ¤ ”正在作为 html 特殊字符执行。

This is query getting...这是查询得到...

merchant_id=123456789&order_id=xxxxxxxx&amount=1.00¤cy=INR&language=EN&billing_name=gfgh ghfhgfgh&billing_address=abc&billing_city=abc Merchant_id=123456789&order_id=xxxxxxxx&amount=1.00¤cy=INR&language=EN&billing_name=gfgh ghfhgfgh&billing_address=abc&billing_city=abc

As per the html entities, ¤根据 html 实体, ¤ belongs to ¤, when you use &currency in the URL, it automatically gets converted to ¤cy.属于 ¤,当您在 URL 中使用 &currency 时,它会自动转换为 ¤cy。 Even last semicolon (;) is not there in the &curren, it still creates ¤ html entity.即使最后一个分号 (;) 不在 &curren 中,它仍然会创建 ¤ html 实体。 Solution to this problem is这个问题的解决方法是

  1. to either use urlencode urlencode(merchant_id=123456789&order_id=xxxxxxxx&amount=1.00&currency=INR&language=EN&billing_name=gfghghfhgfgh&billing_address=abc&billing_city=abc) or要么使用urlencode urlencode(merchant_id=123456789&order_id=xxxxxxxx&amount=1.00&currency=INR&language=EN&billing_name=gfghghfhgfgh&billing_address=abc&billing_city=abc)要么
  2. to use html entity for & character like amount=1.00&currency=INR将 html 实体用于 & 字符,如amount=1.00&currency=INR

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

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