Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- #Below is full list of available characters.
- #"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"
- $fp=fopen("/dev/urandom","r") or die;
- $available_chars="23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnpqrstuvwxyz";
- do{
- $minikey='S';
- for($i=0;$i<29;$i++){
- while(($c=ord(fgetc($fp)))>=strlen($available_chars));
- $minikey.=substr($available_chars,$c,1);
- }
- $check=hash('sha256',$minikey . '?') . "n";
- }while(substr($check,0,2)!='00');
- fclose($fp);
- $priv=hash('sha256',$minikey);
- print "Minikey: $minikeyn";
- print "Privkey: $privn";
- ?>
- <?
- require_once( "cryptobox.class.php" );
- $options = array(
- "private_key" => "", // private key from gourl.io
- "orderID" => "your_product1_or_signuppage1_etc",
- "amountUSD" => 2 // 2 USD
- );
- // Initialise Payment Class
- $box1 = new Cryptobox ($options);
- // Display Payment Box or successful payment result
- $paymentbox = $box1->display_cryptobox();
- // A. Process Received Payment
- if ($box1->is_paid())
- {
- // Your code here to handle a successful cryptocoin payment
- // ...
- }
- else $message .= "The payment has not been made yet";
- ?>
- <!DOCTYPE html>
- <html><head></head>
- <body>
- <?= $paymentbox ?>
- <?= $message ?>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement