Getting ID of an element. Laravel 5.1

Tuesday, November 3, 2015

What I need to do is to get the ID of the element.



$price = $_POST['price'];
$orderid = $_POST['id'];
$serverId = 'localhost:8000';


$request = WebToPay::redirectToPayment(array(

'projectid' => *****,
'sign_password' => '************************',
'orderid' => $orderid,
'amount' => $price * 100,
'currency' => 'EUR',
'country' => 'LT',
'accepturl' => url().'/redirect-to-server/'.$orderid,
'cancelurl' => $self_url.'/cancel.php',
'callbackurl' => url().'/get-bank-callback',
'test' => 1,


This code above redirects me to the accepturl wich is fine. But how I manage to get ID of the file in the accepturl file ?



As you can see in the code above I even post an ID of the element, but I don't know how to get it into the accept.php



This is my accept.php



<?php
$id = $_GET['orderid'];
?>


Thank you for buying <?php echo $id ?>


And it doesn't work like that

0 comments:

Post a Comment