SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast
    Join Date
    Aug 2006
    Posts
    39
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    running an excutable file using php

    Hi,

    I am integrating my website with HSBC payment transaction system. I did my test transaction manually and it was succesful. I am trying to replicate this live but I am having problems. The step I need help with, is How can I run an executable file using php?

    here are the details of what I am trying to achieve:

    1) I have a script that submits values to a file called TestHash.e which takes these values and generate an order hash.

    Here is my script (the file is called testme):


    PHP Code:
    ./TestHash.e  "IYQTxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "UKxxxxxxxxGBP"  "1184609452210" "./confirm2.php" "./confirm2.php" "3409423743" "testorderm" "3499" "826" "Auth" "some data" "T" "Testuser10" "Jo" "Blog" "22 Clifton Road" "Here" "Glasgow" "G11 2NP" "826" "mel@emailb.com" "Jo" "Blog" "22 Clifton Road" "Here" "Glasgow" "G11 2NP" "826" 

    2) For testing I ran this file from the linux shell.



    PHP Code:
    bash testme 

    This generates an order hash value for this user which I take and submit in an html form along with the other data (the store ID, customer name, address etc. all the values that i included in the testme file). The form posts the values to HSBC payment system for payment, validation etc.

    NOW, I would like to go live and HSBC have not being helpful. I am stuck on how to submit the user values as well as the HSBC values (store id, etc) to the testme file (which runs testhash.e) using php. OR, may be directly submitting the values and running the Testhash.e from within my code without having to use the testme file.

    I would really appreciate your help.

  2. #2
    SitePoint Member
    Join Date
    Jul 2006
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    http://us2.php.net/exec Be VERY careful using that function,please.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •