Sedang Disiapkan

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);

}

Kemahiran: PHP, Sekuriti Web

Lihat lebih lanjut: 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, convert php function, post php, post data php, asp post data, asp function return, php global, post php data, asp php global, php global data, php str, asp post, convert function php, convert true

Tentang Majikan:
( 64 ulasan ) Glendale, United States

ID Projek: #4042387

Dianugerahkan kepada:

mgraph

Hi, check inbox

$30 USD dalam sehari
(67 Ulasan)
4.5

8 pekerja bebas membida secara purata $35 untuk pekerjaan ini

TopSEOExpertscom

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

$30 USD dalam sehari
(187 Ulasan)
7.7
VileGnosis

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

$30 USD dalam 0 hari
(159 Ulasan)
6.6
k1ng440

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

$50 USD dalam 3 hari
(88 Ulasan)
6.4
angelmiks2007

Clear with requirements. Ready to start. Thanks

$40 USD dalam 0 hari
(36 Ulasan)
5.8
sveralex

Hello, here is my bid

$40 USD dalam sehari
(30 Ulasan)
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 dalam 0 hari
(9 Ulasan)
3.9
crispinsmith2010

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

$30 USD dalam 0 hari
(9 Ulasan)
3.3
Torricelli

I can get this job done right away!

$30 USD dalam 0 hari
(3 Ulasan)
1.9