问题描述
We have a custom product designing tool at "http://dev.ejuicysolutions.com/custom_shirt_designer/". When user will be finished with formatting with text etc... they will click on print button, where they can print but we need to extend functionality from print to "Save Image, as shown in Canvas" and then email that image. Email can be done but the main problem we are facing is that image is being saved on server but all other formatting like text are not being saved along with. Either script is just placing text etc using styles... on above the canvas... Any idea, how it can be achieved?
预先感谢!
Thanks in advance!
推荐答案
如果我理解此权限,则需要将画布内容导出到图像,处于用户完成工作的状态?画布内部有一个导出功能. canvas.toDataURL().这样,您将获得base64图像,默认为png格式.
If i understand this right, you need to export the canvas content to an image, in the state it is when the user finished his work? There is an export function inside the canvas. canvas.toDataURL(). That way you get a base64 image, default is png format.
这篇关于画布以保存图像和电子邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!