jquery-word-exportプラグイン(Marks Windollによって開発された)を使用して、私のWebページを.docドキュメントにエクスポートしています。 Google Chromeではすべてうまく動作しますが、Mozilla Firefoxではうまく動作しません。エクスポートボタンをクリックすると、次のエラーが表示されます。jQuery単語のエクスポートエラー
SyntaxError: export declarations may only appear at top level of a module
NS_ERROR_NOT_AVAILABLE
奇妙なことは、ウェブページをリフレッシュすることによって時々動作します。
これはどういう意味ですか、これをどのように解決できますか?
(おそらく別のエクスポートライブラリを使用して)別の解決策はありEDIT:
<div id="export-content">
<!-- PROFILE PICTURE -->
<div id="divProfielfoto" ng-controller="profielfotoCtrl">
<img id="profielfoto" ng-src="{{profielfoto}}" alt="profielfoto" style="width: 125px;height:125px;margin-bottom: 20px; border-radius:50%; border: 7px solid orange;" /></div>
<input style="display: none;" id="profileUpload" type="file" accept="image/*"/>
<!-- PROFILE PICTURE END -->
</div>
<button class="word-export" onclick="export()">Export as .doc</button>
と、次のようにエクスポートするためのコードは次のとおりです:
$(".word-export").click(function (event) {
$("#export-content").wordExport("CV " + naam);
});
あなたのコードを共有します – brk
は、firefoxではなくchromeで使用されているjsfiddle o plunrリンクを共有します。 –
あなたはonclick属性を削除してみることができます。 – reza