Link to home
Start Free TrialLog in
Avatar of Mico Beldad
Mico Beldad

asked on

Merge Image save to mysql database without clicking anything

Can anyone help me about my problem?
I have successfully merge a image but i dont know how to insert it into DB

the code is something like this
 <?php
      $logo = "SecurityBank.png";
      $white_image = "image_size.png";
      $targetfile = "Phobo_New_Image.png";

      $Whitebackground = imagecreatefrompng($white_image);
      $whitebgW = imagesx($Whitebackground)-300;
      $whitebgH = imagesy($Whitebackground);
                        
      $partnerlogo = imagecreatefrompng($logo);
      $partnerlogoW = imagesx($partnerlogo);
      $partnerlogoH = imagesy($partnerlogo);
                  
      $photoFrame = imagecreatetruecolor($whitebgW,$whitebgH);
        $destlogo_x = $whitebgW - $partnerlogoW;
      $destlogo_y = $whitebgH - $partnerlogoH;
                  
      imagecopyresampled($photoFrame, $Whitebackground, 0, 0, 0, 0, $whitebgW, $whitebgH,$whitebgW, $whitebgH);
      imagecopy($photoFrame, $partnerlogo, $destlogo_x-300, $destlogo_y-400, 0, 0, $partnerlogoW, $partnerlogoH);
      imagepng($photoFrame, $targetfile);
?>
<center><img src="<?php echo $targetfile ?>" width="700px" name="target" id="target" height="400px"></center>'

<!-----THE NEW MERGED IMAGE IS BEEN SHOWED
name="target" id="target"
--->

I want to insert it into datbase my setTimeout or anything that the file $target is save into to the database as blob or longtext.
ASKER CERTIFIED SOLUTION
Avatar of Ray Paseur
Ray Paseur
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Avatar of Eddie Shipman
Eddie Shipman
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial