RemoveJavaScriptFromLinks
HtmlFixedSaveOptions.RemoveJavaScriptFromLinks property
Specifies whether JavaScript will be removed from links. Default is false
. If this option is enabled, all links containing JavaScript will be replaced with “javascript:void(0)”.
public bool RemoveJavaScriptFromLinks { get; set; }
Examples
Shows how to remove JavaScript from the links.
Document doc = new Document(MyDir + "JavaScript in HREF.docx");
HtmlFixedSaveOptions saveOptions = new HtmlFixedSaveOptions();
saveOptions.RemoveJavaScriptFromLinks = true;
doc.Save(ArtifactsDir + "HtmlFixedSaveOptions.RemoveJavaScriptFromLinks.html", saveOptions);
See Also
- class HtmlFixedSaveOptions
- namespace Aspose.Words.Saving
- assembly Aspose.Words