跳到主要内容

更新超链接 - 链接管理器 Make

PDF4me 更新超链接 是一个 Make 搜索现有模块 PDF 通过文本或超链接 URL 并批量替换它们,而不会影响文档的其余部分。可用于修复损坏的链接、迁移 URLs 网站重组后,或批量更新品牌形象后 PDFs

本模块的功能

PDF4me 更新超链接 搜索 PDF通过其可见文本或其现有超链接 URL然后批量替换匹配项。每个超链接项都可以定位到文本或 URL替换部分或全部值,并可选择将搜索值视为正则表达式,以便一次性跨多个链接进行基于模式的匹配。

相关博客文章
目前尚无关于此功能的博客文章——敬请期待。
在此期间,您可以浏览 PDF4me 博客,查看适用于各平台的教程和工作流程。
访问博客

我如何验证我的身份 Make 设想?

每一个 PDF4me 模块 Make 需要有效 联系创建或选择一个可以容纳您的 PDF4me API 关键在于确保该方案能够安全地验证超链接更新请求。

您不容错过的重要事实

搜索方式选择文本或网址
每个“超链接”项要么搜索可见的链接文本,要么搜索底层 URL 值,两者不会同时搜索。请为需要更新的每个维度添加单独的项。
空白文本当前值替换整个匹配项
将“文本当前值”留空,即可将整个匹配的文本或 URL 替换为“文本新值”,而不是仅替换其中的一部分。
表达式是否启用正则表达式匹配
将“是表达式”设置为“是”,可将搜索值视为正则表达式,这对于在一个条目中匹配一系列 URL(例如,具有不同路径的旧域)而不是列出每个 URL 非常有用。
将 PDF4me PDF 更新为“超链接”模块,并配置连接、文件类型为“映射”,映射文件名和文档/公共文件 URL,以及一个“超链接”项,该项显示“搜索开启”、“文本当前值 Prince”、“文本新值 Queen”、“搜索值 Drylab”,并将“表达式”设置为“否”。

将文件设置为映射,连接文件名和文档/公共文件 URL,然后为每个要更新的链接模式添加一个超链接项。

参数

必需的: 必须提供连接信息、文件名、文档/公共文件 URL,以及至少一个包含“搜索条件”和“搜索值”的超链接项。“当前值文本”、“新值文本”和“表达式”为可选信息。

范围必需的它的作用例子
ConnectionRequiredPDF4me API connection. Click Add and paste your API key if connecting for the first time.My PDF4me connection
File NameRequiredFilename of the source PDF including extension, used for output file identification.brochure.pdf
Document / public file URLRequiredBinary PDF content mapped from a preceding module, or a public URL to the file.[Buffer from Get File]
Hyperlinks > Search OnRequiredWhether this item searches the hyperlink text or the URL value.Text
Hyperlinks > Text Current ValueOptionalThe text or URL substring to replace. Leave blank to replace the entire matched value.Prince
Hyperlinks > Text New ValueOptionalThe new text or URL value to set in place of the match.Queen
Hyperlinks > Search ValueRequiredThe hyperlink text or URL value to search for in the document.Drylab
Hyperlinks > Is ExpressionOptionalYes evaluates Search Value as a regular expression instead of a literal match. Defaults to No.No

输出字段

场地类型它包含什么
NameStringOutput PDF filename with updated hyperlinks.
Doc DataBufferThe PDF document with modified links, in buffer format, ready to upload or attach.

如何在更新中设置超链接 Make

  1. 添加 PDF4mePDF - 更新超链接 致你 Make 设想。
  2. 选择 联系 (或点击) 添加 用你的 PDF4me API 钥匙)。
  3. 在下面 文件, 选择 地图 电线 文件名文档/公共文件 URL 来自之前的模块。
  4. 点击 添加项目 在下面 超链接 对于每个需要更新的链接模式。
  5. 搜索Text 或者 URL然后填充 搜索值 要寻找什么。
  6. 文本 当前值 (或留空以替换整个匹配项) 文本新值 替换后。
  7. 是表达式Yes 如果搜索值是正则表达式,则运行该场景。更新后 PDF 返回一个缓冲区。

典型配置

工作流程示例Common Make scenario patterns using Update Hyperlinks.
定期清理失效链接
  1. 每月定期触发一次,以审查已发布的文件。 PDFs
  2. 获取文件检索每个 PDFDropbox 或者 Google Drive 在迭代器循环中。
  3. 更新超链接,替换已知的失效或重定向链接。 URLs 每个已知无效链接使用一个超链接项。
  4. 更正后的 PDF 已上传回存储设备,替换先前的版本。
网站重组后的域名迁移
  1. 营销团队确认新网站结构上线后,将触发特定场景。
  2. 迭代器处理每个 PDF 它指向的是旧域名。
  3. 更新超链接将搜索设置为 URL,表达式为“是”,并且在单个项目中将旧域模式与新域模式进行匹配。
  4. 更新 PDFs 保存到文档库,并刷新搜索索引。
重新打造品牌营销材料
  1. 品牌重塑项目会触发对所有营销活动的批量审查。 PDFs
  2. 更新超链接会运行多个项目:一个用于域名更改,一个用于社交媒体账号,一个用于联系电子邮件链接文本。
  3. 每个 PDF 通过迭代器中的相同超链接配置进行处理。
  4. 品牌重塑 PDFs 已上传至更新后的资料文件夹,准备分发。

实用技巧

Search On decides text vs URL, not both
One Hyperlinks item cannot search text and URL simultaneously. Add a separate item for each dimension if you need to update both.
Blank Text Current Value replaces everything
If Text Current Value is left empty, the entire matched hyperlink text or URL is replaced with Text New Value, not just a substring.
Regex needs Is Expression set to Yes
Search Value is treated as a literal string unless Is Expression is Yes. Forgetting this toggle is the most common reason a regex-style Search Value fails to match.
One item per link pattern, not per link instance
A single Hyperlinks item updates every matching link in the document, you do not need one item per occurrence, only per distinct search pattern.
This module edits links, it does not add them
Update Hyperlinks only modifies hyperlinks that already exist in the PDF. To insert brand-new links, use the PDF4me Create Hyperlinks module.
Test with one item before batching many PDFs
Run the scenario against a single sample PDF first to confirm Search On and Search Value match as expected before applying it to a large batch.

速查表

场地价值
ModulePDF - Update Hyperlinks
ConnectionPDF4me API key
Search On optionsText or URL
Blank Text Current ValueReplaces the entire matched value
Is ExpressionYes = regex match, No = literal match (default)
Multiple updatesAdd one Hyperlinks item per link pattern
OutputName + Doc Data buffer

常见问题

Can I search by link text or by URL?+
Yes. Set Search On to target either the visible hyperlink text or the underlying URL value. Each Hyperlinks item searches on one dimension at a time, add a separate item if you need to match both.
How do I replace only part of a link’s text?+
Set Text Current Value to the substring you want to find and Text New Value to its replacement. Leave Text Current Value blank to replace the entire matched value instead of a partial substitution.
What does the Is Expression option do?+
When Is Expression is set to Yes, Search Value is evaluated as a regular expression instead of a literal string match. This is useful for matching a whole family of similar URLs (for example an old domain with varying paths) in a single item. See <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_expressions" target="_blank" rel="noopener noreferrer">MDN's regular expressions guide</a> for pattern syntax.
Can I update multiple different links in one run?+
Yes. Add one Hyperlinks item per distinct link pattern you want to update. Each item runs independently against the same document, so a single module call can fix several unrelated links at once.
Does it insert new hyperlinks or only modify existing ones?+
Update Hyperlinks only modifies links that already exist in the PDF. To add brand-new hyperlinks to a document, use the PDF4me Create Hyperlinks module instead, which is documented under the <a href="https://www.iso.org/standard/75839.html" target="_blank" rel="noopener noreferrer">PDF 32000-2:2020 link annotation specification</a>.

行业应用案例及应用

  • 修复失效链接更新失效的超链接 PDFs
  • URL 移民: 改变 URLs 网站重组之后
  • 域名变更域名迁移后更新链接
  • 重定向更新替换重定向 URLs 决赛

相关操作

在其他平台上执行相同任务

获取帮助