Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Shells Virtual Desktop
BMail.ag - Secure Email Service
Server.net
CPLicense.net
VPS Server
Buy VPN
Vultr
VMs for AI
HostDare
ReliableSite White-Label Dedicated Hosting for Resellers
InterServer VPS
BMail.ag - Secure Email Service
Best VPN
High-Performance Bare Metal Server Solutions
Karvl.com
Server Mania Cloud Hosting
DataWagon Hosting
AlphaVPS Hosting
Evoxt.com
Clouvider
VPS Hosting with NVMe
Residential IPs in the US & 4G Mobile Proxies in EU & US with Unlimited Bandwidth
ReliableSite White-Label Dedicated Hosting for Resellers
Rabisu - Hosting Solutions
Shells Virtual Desktop
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

PHP Coding Help

peachstolipeachstoli Member
edited June 2013 in Help

How can i get these values on that proccess.php

$code = '<form method="http://mydomain.com/paytm/process.php">
<input type="hidden" name="username" value="'.$gatewayusername.'" />
<input type="hidden" name="invoiceid" value="'.$invoiceid.'" />
<input type="hidden" name="amount" value="'.$amount.'" />
<input type="submit" value="Pay Now" />
</form>';


return $code;

Comments

  • Change:

    <form method="http://mydomain.com/paytm/process.php">

    To:

    <form method="post" action="http://mydomain.com/paytm/process.php">

    And in process.php process the $_POST array?

  • peachstolipeachstoli Member
    edited June 2013

    @sleddog said:
    Change:

    <form method="http://mydomain.com/paytm/process.php">

    To:

    <form method="post" action="http://mydomain.com/paytm/process.php">

    And in process.php process the $_POST array?

    It won't work in whmcs. Its a custom payment gateway.

  • I have no knowledge of whmcs, but an html form's "method" must be either "get" or "post". Providing a URL is incorrect.

  • function template_link($params) {

    # Gateway Specific Variables
    $gatewayusername = $params['username'];
    $gatewaytestmode = $params['testmode'];
    
    # Invoice Variables
    $invoiceid = $params['invoiceid'];
    $description = $params["description"];
    $amount = $params['amount']; # Format: ##.##
    $currency = $params['currency']; # Currency Code
    
    # Client Variables
    $firstname = $params['clientdetails']['firstname'];
    $lastname = $params['clientdetails']['lastname'];
    $email = $params['clientdetails']['email'];
    $address1 = $params['clientdetails']['address1'];
    $address2 = $params['clientdetails']['address2'];
    $city = $params['clientdetails']['city'];
    $state = $params['clientdetails']['state'];
    $postcode = $params['clientdetails']['postcode'];
    $country = $params['clientdetails']['country'];
    $phone = $params['clientdetails']['phonenumber'];
    
    # System Variables
    $companyname = $params['companyname'];
    $systemurl = $params['systemurl'];
    $currency = $params['currency'];
    
    # Enter your code submit to the gateway...
    
    $code = '<form method="http://www.domain.com/submit">
    







    ';

    return $code;
    

    }

    Same as their dev kit.

  • NickGHNickGH Member

    I know a pretty good amount of PHP and I have to agree with @sleddog the method is either post or get. The action is the url for the processing. Am I right to assume you are creating a custom payment page?

  • @NickGH @sleddog
    Its post. I figured it out. But they didn't included in devkit.
    Now its working.

    Thank you guys.

  • NickGHNickGH Member

    Your welcome. if you have any more road blocks pm me or email me at [email protected]

Sign In or Register to comment.