Re: Marty Yantzie - COM Object help- have working .asp example - Paymentech

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Marty Yantzie  wrote a question about Paymenttech and php back in July
of 2003.  Marty did you ever get this figured out.  
 
Anybody else, has anyone else run into problems with this?
 
 
Original Message:
I am trying to setup an small ecommerece site. I would like to use php 
to accomplish this. I have been able to get the .asp example to work 
fine but am having trouble getting the asp converted to php. Am i 
heading in the right direction? Any ideas? 


Here is a trimmed version of the PHP that I am trying to use. 


<? 
 $trans = new COM("Paymentech.Transaction")or die("Unable to instanciate

Payment Transaction"); 
 $trans->Type = 'CC.Authorize'; 
 $trans->Field('MessageType')='AC; 
 $trans->Field('MerchantID')='1234567890123'; 
 $trans->Field('BIN')='000002'; 
 $trans->Field('AccountNum')='1234567890123'; 


 $Resp = $trans->Process(); 
?> 
------------------------------------------------------------------------

----- 
Here is the ASP that works 


<% 
 Dim trans 
 Set trans = Server.CreateObject ("Paymentech.Transaction") 
  
    trans.Type = "CC.Authorize" 
    trans.Field("MessageType") = "A" 
   
    trans.Field("MerchantID") = Request("MerchantID") 
    trans.Field("BIN") = Request("BIN") 
    trans.Field("AccountNum") = Request("AccountNum") 
    trans.Field("OrderID") = Request("OrderID") 
    trans.Field("Amount") = Request("Amount") 
    trans.Field("Exp") = Request("ExpDate") 
    trans.Field("AVSname") = Request("AVSName") 
    trans.Field("AVSaddress1") = Request("AVSAddress1") 
    trans.Field("AVScity") = Request("AVScity") 
    trans.Field("AVSstate") = Request("AVSstate") 
    trans.Field("AVSzip") = Request("AVSzip") 
    trans.Field("Comments") = Request("Comments") 
    trans.Field("ShippingRef") = Request("ShippingRef") 
      
 Set Resp = trans.Process () 
%> 


 
Charles Killmer
Netgain Technology
CharlesK@xxxxxxxxxxxxxxxxxxxxx
Office: (320) 251-4700 ext 107
 

[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux