The code below displays a signature on the screen previously signed on the form before. It has now displayed the image as a png. How do i go about saving the image into a mysql database field so i can recover the picture as and when i need to / or even if easier save the file to the server in a folder called signatures under a file name of my choice i.e by orderidno variable.
any help is greatfull
<?php require_once 'signature-to-image.php'; $output = $_POST['output']; $img = sigJsonToImage($output); // Save to file imagepng($img, 'signature.png'); // Output to browser header('Content-Type: image/png'); imagepng($img); // Destroy the image in memory when complete imagedestroy($img); ?>
Edited by kardklub: added code