dqcuq4138 2010-06-16 19:08
浏览 65

php脚本从md5生成校验和

In order to calculate the checksum i need following things. these parameters are concatenated in a constant (no spaces) string made up of the values of the following parameters in the exact order listed below: o Secret Key o Merchant id o Currency o Total amount o Item list (item_name_1, Item_amount_1, item_quantity_1 to item_name_N, Item_amount_N, item_quantity_N) o Timestamp

e.g In that case the string befor hash will be: pLAZdfhdfdNh57583USD69.99Tier2 item69.9912010-06-14.14:34:33

And using the MD5 hash function the result is: ghvsaf764t3w784tbjkegbjhdbgf

i want to know how can i create a php script that will call md5 hash function with the inputs given above and based on that it will generate the hash function value that will be the checksum value for my coding..

  • 写回答

2条回答 默认 最新

  • dpppic5186 2010-06-16 19:54
    关注

    try

    echo md5('pLAZdfhdfdNh57583USD69.99Tier2 item69.9912010-06-14.14:34:33');
    

    That will do exacly what you asked. Unless you need help writting the whole script.

    评论

报告相同问题?

悬赏问题

  • ¥15 想通过pywinauto自动电机应用程序按钮,但是找不到应用程序按钮信息
  • ¥15 MATLAB中streamslice问题
  • ¥15 如何在炒股软件中,爬到我想看的日k线
  • ¥15 51单片机中C语言怎么做到下面类似的功能的函数(相关搜索:c语言)
  • ¥15 seatunnel 怎么配置Elasticsearch
  • ¥15 PSCAD安装问题 ERROR: Visual Studio 2013, 2015, 2017 or 2019 is not found in the system.
  • ¥15 (标签-MATLAB|关键词-多址)
  • ¥15 关于#MATLAB#的问题,如何解决?(相关搜索:信噪比,系统容量)
  • ¥500 52810做蓝牙接受端
  • ¥15 基于PLC的三轴机械手程序