Automatically embed all links in indesign?

Learn / Forums / InDesign Add-ons (Scripts, Scripting, and Plug-ins) / Automatically embed all links in indesign?

Viewing 6 reply threads
  • Author
    Posts
    • #59718
      Lala Lala
      Participant

      Is there a script to do this? I'd love to have some setting that just automatically embeds everything… whether it's placed, copy/pasted, drag-n-dropped, whatever. I understand the risks as far as creating huge filesizes.

      Ideally this would happen with zero interaction from me, the idea is I skip the process of opening the links panel and manually doing it… it just happens quietly in the background with every graphic I use.

    • #59758

      var doc = app.activeDocument;
      var links = doc.links;

      for (var i = links.length-1; i >= 0; i–) {
      links[i].unlink();
      }

    • #59762
      Lala Lala
      Participant

      very nice, I'm looking forward to trying this. Thank you!

    • #63648
      judybinfo
      Member

      VERY USEFUL – thanks. Note: the “i-” is two negative signs (i–), not 1(i-). I copied and pasted so didn't notice until the script fails. I was able to also create an unembed script for storing on my computer after sending to printer. Great idea!

    • #63649
      Lala Lala
      Participant

      Thanks Judy, and thanks also to Kasyan.

      If anyone else was confused, Judy's saying that the script won't work if you copy and paste it as-is, because a critical part of it got changed when Kasyan posted it. The forum software automatically changes two dashes to a long dash without asking you. After about twenty edits I think I've figured out how to properly work around this and give you copy – paste-able code.

      var doc = app.activeDocument;
      var links = doc.links;

      for (var i = links.length-1; i >= 0; i DASH DASH LOL) {
      links[i].unlink();
      }

      Actually, after twenty edits, I give up. A change would have to be made by the forum administrator to fix this “useful” “feature” of wordpress forums. Seemingly nothing I do can allow two dashes to be typed side-by-side, which breaks a ton of copy/pasted code I'm sure.

    • #63662

      @CreeDo – a shorter version without the two dashes would be:

      app.activeDocument.links.everyItem().unlink();

      Uwe

    • #14398263
      Heidi Rosendall
      Participant

      This looks very cool, however, I’ve never created my own script before, I’ve uploaded them but not made them. So, do I paste the final code into a text file and save it with the script extension? Any caveats?

Viewing 6 reply threads
  • You must be logged in to reply to this topic.
>
Notice: We use cookies on our websites to give you a great online experience. If you keep browsing, we'll assume you're ok with this. For more information, see our privacy policy. By closing this banner, you agree to the use of cookies.I AGREENo