2
1
I work for a small publishing company, and we regularly create catalogues, brochures, etc., where we feature various hand-picked subsets of our available titles.
Based on the titles that are to be included in a catalogue, I create (in PHP, on my localhost, so very flexibly) an XML file with all the metadata of each book, including a link to the cover of the book.
All our cover images, named by the ISBN of the book in question, are located in a folder on a network drive that I log on to via Samba (authenticating with user name and password) and then mount on the desktop of my working machine (a Mac running OS X Yosemite).
I then import the XML file into an InDesign (CS6) document to layout the actual catalogue.
Everything about this work flow works perfectly and very elegantly—except for the fact that InDesign seemingly refuses to find any image whose href
path leads to somewhere not on the local hard drive.
Various places online, I have found references (like page 6 of this PDF by Cari Jansen) that say that InDesign expects the href
path to be formatted as follows (leaving out the href=
bit and the quoting):
Image is in same folder as XML file:
file:///image.jpg
(orfile:image.jpg
)
Image is in a subfolder:file:///images/image.jpg
Image on hard drive, absolute path name:file:///Users/username/ Documents/Blablabla/images/image.jpg
Image is on another volume (server/network drive):file:///Volumes/VolumeName/RestOfPath
That’s as much description as I can find anywhere, but that does not work. At least not with files on this network drive.
If I give a relative path to a file in the same folder where the XML file is, or a subfolder, then it works fine. If I give an absolute path to a folder on the OS drive (i.e., /Users/username/Blablabla/...
), it works fine, too.
But if I link to the file on the network drive, in the format file:///Volumes/NetworkDrive/CoverImages/9781234567890.ext
, InDesign does not find the file. It just gives me a “Find file” dialog box where I can then select the image in the file list. Once I select the image and hit “OK”, it works fine: the image shows up. But that’s not particularly practical when I need perhaps 60 or 70 out of about 2,500 images in that folder.
I have of course made sure that the file I link to is actually there in the folder—in two ways. First, the path in the XML file is created automatically in PHP based basically on a glob
search in the file list of that folder; and second, using cp
(with the path copied from the XML file) to copy the image file to a folder on my local drive works just fine (so at least the OS X Terminal sees the /Volumes/NetworkDrive/CoverImages/9781234567890.ext
as a completely valid one).
This happens with all files.
Is there no way of getting InDesign to accept image paths on (SMB) network drives?
(I have read and understood this question, but that deals with Data Merge, which—annoyingly—uses a different format for linking to files. And yes, I realise my method would mean the link to the images would break if I open the document while the network drive is not mounted—that’s a calculated drawback I’m willing to live with.)
Am I understanding correctly that InDesign will find the directory that contains the file, but not the file itself? And it then presents a dialog to browse that directory where you can see the file in a list and you choose that file, at which point it accepts/finds the file and it works? – drootang – 2015-07-30T12:49:36.427
@drootang I don’t believe there’s any way to find out for sure if it finds the directory or not. The “Find file” dialog always opens at the same folder where it was the last time it was closed, so if that happens to be the
CoverImages
folder, it’s the right directory—otherwise, it’s not. – Janus Bahs Jacquet – 2015-07-30T13:36:33.190@drootang I see I forgot to answer the second of your questions. Yes, once I manually select the image in the directory, it accepts it and it works. Unfortunately, that doesn’t change the
href
value in the Structure pane, and the Links pane only gives the ‘regular’ path (/Volumes/NetworkDrive/...
), not the only-needed-in-XMLfile:///
path, so I can’t use that to try to find out what’s going wrong. :-/ – Janus Bahs Jacquet – 2015-07-30T14:25:15.613How are you mounting the samba share? The only thing I can think of is that perhaps the InDesign file browser is using the same mechanism that is blocked by the -nobrowse option when you mount the volume. If you connected using the Finder and Go->Connect to Server... this won't be the case. You could try playing around with the options in
man mount_smbfs
. If you put the file URL into Safari does it open? – drootang – 2015-07-31T12:45:45.650@drootang I do connect to the drive via Finder -> Go -> Connect to server, not manually via
mount_smbfs
or anything like that. Inputting the URL in Safari’s address field works fine and opens the file no problem. – Janus Bahs Jacquet – 2015-07-31T13:12:49.750