I gang

Convert GET to POST in PHP - repost

Hello,

I have three php functions. I need to convert the last two (processGET, processACH) from a GET to a POST.

Thank You,

function processRequest(){

global $config;

$data = $_POST;

$data['MerchantID'] = $config['MerchantID'];

$data['RegKey'] = $config['RegKey'];

$data['USER2'] = substr($data['AccountNo'],strlen($data['AccountNo'])-4);

$req = new HTTPRequest('[url removed, login to view]','/bill/transac/[url removed, login to view]','POST',true);

$req->connect(html_entity_decode(http_build_query($data)));

$data = parseFields($req->getContent());

return $data;

}

function processGET(){

global $config;

$data = $_POST;

$data['MerchantID'] = $config['MerchantID'];

$data['RegKey'] = $config['RegKey'];

$data['Amount'] = number_format($data['Amount'], 2, '.', '');

$data['USER2'] = substr($data['AccountNo'],strlen($data['AccountNo'])-4);

$str = html_entity_decode(http_build_query($data));

$data = file_get_contents('[url removed, login to view]'.$str);

return parseFields($data);

}

function processACH() {

global $config;

$data = $_POST;

$data['MerchantID'] = $config['MerchantID_ach'];

$data['RegKey'] = $config['RegKey_ach'];

$data['USER2'] = substr($data['AccountNo'],strlen($data['AccountNo'])-4);

$str = html_entity_decode(http_build_query($data));

$data = file_get_contents('[url removed, login to view]'.$str);

return parseFields($data);

}

Færdigheder: PHP, Web Sikkerhed

Se mere: convert post php, web config php, data str, str, convert post data php, php convert post, post process, global php, substr, return data php, req php, regkey, httprequest data, file_get_contents php, file_get_contents http post, php function convert php, post file_get_contents, php post file_get_contents, file_get_contents post php, file_get_contents php post, convert php function, php file_get_contents php, php file_get_contents post, file_get_contents post, post php

Om arbejdsgiveren:
( 64 bedømmelser ) Glendale, United States

Projekt-ID: #4042387

Tildelt til:

mgraph

Hi, check inbox

$30 USD på 1 dag
(67 bedømmelser)
4.5

8 freelancers are bidding on average $35 for this job

TopSEOExpertscom

Hi, Please check PMB for details. We're ready to start right away.

$30 USD på 1 dag
(187 bedømmelser)
7.7
VileGnosis

I have sent a private message to your inbox that contains my relevent skills and any questions I have.

$30 USD in 0 dage
(159 bedømmelser)
6.6
k1ng440

Full time freelance web developer with over 8 years of commercial experience.

$50 USD in 3 dage
(88 bedømmelser)
6.4
angelmiks2007

Clear with requirements. Ready to start. Thanks

$40 USD in 0 dage
(36 bedømmelser)
5.8
sveralex

Hello, here is my bid

$40 USD på 1 dag
(30 bedømmelser)
5.4
Ashe93

Please check your PMB! I have sent you a message regarding my bid. I look forward to hearing a response from your end!

$30 USD in 0 dage
(9 bedømmelser)
3.9
crispinsmith2010

Hi , freelancer expert here , Please check PMB. Thanks ,

$30 USD in 0 dage
(9 bedømmelser)
3.3
Torricelli

I can get this job done right away!

$30 USD in 0 dage
(3 bedømmelser)
1.9