Ankush Santra

Certified Magento Developer

Convert Text to an Image using PHP

We generate a coupon code image as example. Here $couponCode is the variable we can change it as we required. And function createImage() is the main part of this task. <?php $couponCode = ‘A153S0C’ ; createImage($couponCode); function createImage($couponCode) { header(“Content-type: image/png”); /* Set the size of Images */ $im = imagecreatetruecolor(400, 400); /* Background Image […]