Fabric.js canvas.toDataURL() sent to PHP by Ajax

后端 未结 5 858
青春惊慌失措
青春惊慌失措 2021-02-06 14:44

I have a problem here when I need create a image with transparent background. I still don´t know if the problem is with fabricjs or with php. Everything works fine when I sent a

5条回答
  •  梦谈多话
    2021-02-06 15:40

    The last step is quite the opposite:

    imagecopyresampled( $img, $alpha_image, 0, 0, 0, 0, $w, $h, $w, $h );
    

    And voila! The image is transparent!

提交回复
热议问题