如何将html中的canvas标签转换为word文件?
how to convert canvas tag in html to a word file?
我不知道如何将 canvas 标签转换为 word 文件。
我尝试使用 this tutorial jQuery Word Export 插件,但出现此错误:
TypeError: $(...).wordExport is not a function
这是我的代码:
jQuery(document).ready(function($) {
$("a.word-export").click(function(event) {
$("#page-content").wordExport();
});
});
这可能是您的代码有问题,或者没有加载。可能 WordExport 不存在于您的源代码中或未加载到您的脚本中。
<script src='https://cdnjs.cloudflare.com/ajax/libs/jquery/3.0.0-rc1/jquery.min.js'></script>
<script src='https://cdnjs.cloudflare.com/ajax/libs/FileSaver.js/2014-11-29/FileSaver.min.js'></script>
// And here link to file of jquery.wordexport.js source
检查这个 fiddle https://jsfiddle.net/mansim/at148xnm/
它在哪里工作,看看你做错了什么
我不知道如何将 canvas 标签转换为 word 文件。
我尝试使用 this tutorial jQuery Word Export 插件,但出现此错误:
TypeError: $(...).wordExport is not a function
这是我的代码:
jQuery(document).ready(function($) {
$("a.word-export").click(function(event) {
$("#page-content").wordExport();
});
});
这可能是您的代码有问题,或者没有加载。可能 WordExport 不存在于您的源代码中或未加载到您的脚本中。
<script src='https://cdnjs.cloudflare.com/ajax/libs/jquery/3.0.0-rc1/jquery.min.js'></script>
<script src='https://cdnjs.cloudflare.com/ajax/libs/FileSaver.js/2014-11-29/FileSaver.min.js'></script>
// And here link to file of jquery.wordexport.js source
检查这个 fiddle https://jsfiddle.net/mansim/at148xnm/
它在哪里工作,看看你做错了什么