myPOS pay button intergration

În desfăşurare Postat la acum 2 ani S-au achitat serviciile după ce au fost prestate
În desfăşurare S-au achitat serviciile după ce au fost prestate

Hello,

I need some one to integrate myPOS pay button in my website.

[login to view URL]

It looks like this now but it doesn`t work. I need someone to make it work.

<?php

// API url

$url = '[login to view URL]';

// Collection object

$data = [

"item_name"=> $teamInfo['priceTitle1'] . " с " . $teamInfo['name'],

"item_price" => $teamInfo['price'],

"pref_language" => "BG",

"currency" => "BGN",

"account_number" => "",

"custom_name" => "ПЛАТИ",

"quantity" => 1,

"website" => "[login to view URL]",

"send_sms" => false,

"send_email" => true,

"button_size" => 1,

"ask_for_customer_name" => true,

"ask_for_shipping_address" => false,

"ask_for_customer_email" => true,

"ask_for_customer_phone" => true,

"cancel_url" => "[login to view URL]",

"return_url" => "[login to view URL]"

];

// Initializes a new cURL session

$curl = curl_init($url);

// Set the CURLOPT_RETURNTRANSFER option to true

curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);

// Set the CURLOPT_POST option to true for POST request

curl_setopt($curl, CURLOPT_POST, true);

// Set the request data as JSON using json_encode function

curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($data));

// Set custom headers for RapidAPI Auth and Content-Type header

curl_setopt($curl, CURLOPT_HTTPHEADER, [

'API-Key: HNTSHVcThE6HWzgMV8fBBVNM',

'X-Request-ID: 232465ab-66ea-4776-b3f0-f7a123f988e4',

'Authorization: Basic base64encode(HNTSHVcThE6HWzgMV8fBBVNM:QN0tGrRRBJBxpGEqSJtQMPOG2PuYhFpitXsBl5lgAJp1ZnhY)',

'Content-Type: application/json'

]);

// Execute cURL request with all previous settings

$response = curl_exec($curl);

// Close cURL session

curl_close($curl);

echo $response . PHP_EOL;

?>

PHP cURL

ID Proiect: #30123140

Detalii despre proiect

3 propuneri Proiect la distanță Activ acum 2 ani

3 freelanceri plasează o ofertă medie de 24€ pentru proiect

nextwebMin

Hello. I'm a web developer with 5 + years experience in PHP and JavaScript and Restful API. I'll share my past project via chat. I hope to discuss more detail via chat. If you give me a chance, I'll improve your websit Mai multe

€35 EUR în 1 zi
(22 recenzii)
5.9
alkajain2906

Hi, I am Senior Full Stack Developer in Website/Software Design & Website Development. I'm an Expert in: -Frontend & Backend Development
-Zend
-Cake PHP -Python -Data Science -Machine Learning -JVM technologies -Jque Mai multe

€19 EUR în 1 zi
(66 recenzii)
6.0
sabakhan456

I am specialised in website design and development and excited for the opportunity to work with you in accomplishing your goals.. I am Good at PHP, Android, MySQL, Javascript, Jquery, Html, Bootstrap and Web Hosting.. Mai multe

€19 EUR în 7 zile
(42 recenzii)
4.9