تخطَّ إلى المحتوى

إضافة الروابط وتحريرها

اجعل عناوين URL في المستند قابلة للنقر، أو أزل الخارجة منها.

تتم المعالجة على جهازك

تعمل هذه الأداة داخل متصفحك بالكامل. لا يُرفع ملفك أبدًا، ويمكنك التحقق من ذلك في تبويب الشبكة بمتصفحك. تحقّق بنفسك: افتح تبويب الشبكة في متصفحك وراقب. سترى طلبًا صغيرًا واحدًا يسأل إن كان لديك مهام متبقية — اسم أداة وبصمة تجزئة، وليس الملف أبدًا.

ماذا تفعل هذه الأداة

A URL printed in a PDF is usually not a link. It is text that looks like one, because whatever produced the document wrote the characters and never created the annotation that makes them clickable. This tool finds those and makes them real, lets you draw links by hand over anything else, and can strip existing links out. Links are annotations laid over a rectangle, so nothing about the page's appearance changes either way.

The common case is a document exported from a design tool or scanned from print where every web address is dead text. The other direction matters too: stripping outbound links from a document before it goes somewhere untrusted, or before it is published, so nobody follows a tracking address that was fine internally.

كيف تعمل

  1. Drop the PDF onto this page.
  2. Leave automatic detection on for a first pass. Every URL and e-mail address found in the text is listed with the page it sits on.
  3. Draw a rectangle over anything else that should be clickable and give it a web address, or a page number to jump to inside the document.
  4. Turn on replacing existing links if the document already carries some and you would rather start clean.
  5. Press Save links and download the result.

Detection is harder than a regular expression over the page text, which is why most tools that offer it miss half the links. A PDF regularly splits one URL across several text runs, so a naive scan finds "https://exa" and "mple.com/report" and links neither. The runs on each line are joined before matching, which finds the whole address. Trailing punctuation is then trimmed - the full stop that ended the sentence rather than the one inside the domain - and a closing bracket is only dropped when it is unbalanced, because plenty of real addresses end in one and truncating those produces a link that leads nowhere. What is not linked is as deliberate as what is. A bare host with no dot in it is rejected, because in running prose "e.g" and "vs" match far more often than "http://localhost" appears, and a wrong link is worse than a missing one. An address beginning www. gets https:// in front of it, since a bare host is not a URI and readers show the annotation as broken. E-mail addresses become mailto: links, and an address inside a URL is not linked twice.

Links are written without a border and with the print flag set. The first is what stops readers drawing the black box round every link that made documents from the 1990s so recognisable; the second is what keeps the link alive when someone prints the document back to PDF. Internal jumps are written as explicit destinations that preserve the reader's current zoom and land at the top of the target page, rather than as named destinations, which break as soon as anyone splits or merges the file.

Running detection twice on the same document adds a second annotation over the same words unless you turn on replacing existing links first. Two stacked links behave unpredictably - readers pick whichever they find first - so turn that option on for a second pass, and leave it off when the document already carries hand-made links you want to keep.

Stripping outbound links is a separate pass and it ignores everything else on the page: every link with a web address is removed and the internal page-to-page jumps are kept, so a document keeps its own navigation and loses its ability to send a reader anywhere. Sanitise PDF is the wider version of this, removing JavaScript, launch actions and embedded files as well.

Detection needs the text of the document, which is read in your browser by PDF.js, and the annotations are written by pdf-lib in a Web Worker. No address in your document is looked up, resolved or checked against anything - which also means a link to a page that no longer exists is written exactly as printed.

ما لا تستطيع هذه الأداة فعله

  • Detection can only find what is in the text layer. A scan has no text until it has been through OCR, and an address broken across two lines is read as two fragments, so neither is linked.

أسئلة يطرحها الناس

لماذا الروابط في ملف PDF عندي غير قابلة للنقر أصلًا؟
لأن الرابط في PDF تعليق - مستطيل مرتبط بإجراء - لا خاصية من خصائص النص. وينشئها Word ومعظم أدوات التصميم حين تلصق عنوانًا، لكن مسارات التصدير تفقدها، والمسح الضوئي لم تكن لديه أصلًا: لديه صورة لعنوان ويب. أما الاكتشاف التلقائي فيقرأ النص ويعثر على العناوين ويكتب التعليقات الناقصة فوقها.
هل يمكنني الربط من صفحة في المستند إلى أخرى؟
نعم. ارسم مستطيلًا وأعطه رقم صفحة بدل عنوان ويب. وتُكتب القفزة وجهةً صريحة تُبقي مستوى تكبير القارئ الحالي وتحطّ أعلى الصفحة الهدف. أما لفهرس كامل، فأداة تحرير العلامات المرجعية أفضل عادةً - فهي تعطي القارئ لوحة جانبية بدل نص قابل للنقر.
كيف أزيل الروابط من ملف PDF؟
طريقتان، وهما تفعلان أمرين مختلفين. تفعيل استبدال الروابط الموجودة يحذف كل رابط قبل كتابة ما أضفته، فيمسحها كلها حين لا تضيف شيئًا. أما إزالة الروابط الخارجية فتخرج فقط تلك المشيرة إلى الويب وتُبقي القفزات بين الصفحات سليمة - وهذا ما تريده لمستند خارج إلى خارج المؤسسة.
بعض عناويني تُكتشف جزئيًا فقط. ما الذي يجري؟
فاصل سطر دائمًا تقريبًا. يجمع الكاشف مقاطع النص داخل السطر الواحد قبل المطابقة، فالعنوان المقسوم على عدة مقاطع في سطر واحد يُعثر عليه كاملًا - أما العنوان الذي يلتف إلى السطر التالي فيصل جزأين، ولا يبدو أي منهما عنوان URL بمفرده. ارسم تلك يدويًا: مستطيل فوق كل سطر، وكلاهما يحمل العنوان نفسه.
هل تُفحص الروابط أو تُرسل إلى أي مكان؟
لا هذا ولا ذاك. لا يُحلّ أي عنوان ولا يُجلَب ولا يُتحقّق منه، ولا يُرفع المستند أبدًا - فاستخراج النص وكتابة التعليقات يجريان معًا في متصفحك. وهذا يعني فعلًا أن خطأً مطبعيًا في عنوان مطبوع يصبح رابطًا بالخطأ نفسه، لذا يستحق الأمر ملاحظة الروابط المعطوبة بوضوح في القائمة قبل الحفظ.

أدوات ذات صلة