如何在 CSV 格式的文件中编码超链接? [英] How to encode a hyperlink in CSV formatted file?
问题描述
当我尝试在 CSV 文件单元格中对 HTML 锚链接进行编码时,它会损坏且 Excel 无法读取.
When I try to encode a HTML anchor link in CSV file cell it becomes corrupted and not readable by Excel.
是否有某种非 HTML 解决方案或格式来对 CSV 文件单元格中的超链接进行编码?
Is there some sort of non-HTML solution or format to encode a hyperlink in CSV file cell?
推荐答案
CSV 文件只是文本 - 由加载程序选择如何解释文本.
A CSV file is simply text - it's up to the loading program how it chooses to interpret the text.
如果 Excel 在您提供它时抱怨 "<a href="blah">Link</a>", "another cell"
然后尝试只使用原始 URL 和您可能会发现 Excel 会自动将其转换为链接.
If Excel is complaining when you feed it "<a href="blah">Link</a>", "another cell"
then try just having the raw URL and you might find Excel will automagically turn it into a link.
但通常 Excel 不处理 HTML,因此期望它从 CSV 文件呈现 HTML 要求过高.
But in general Excel doesn't process HTML, so expecting it render HTML from a CSV file is asking too much.
这篇关于如何在 CSV 格式的文件中编码超链接?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!