One year, we were tasked with making a buyer’s guide. I decided what information we needed while our designer created a layout with options to upgrade. I created a Gravity Form to collect the information. The original plan called for our designer to lay out listings manually, but as our buyer’s guide attracted more attention, and we decided to list each company in multiple categories, if applicable, in the digital flipbook the estimated page count grew unmanageable. We ended up with around 80 pages of listings divided between four sections and hundreds of listings in each in our print version, but around 500 pages in our digital flipbook.
I knew it was possible to export data to XML to InDesign, so I started to research this more. I soon realized I could import listings, with formatting and images, including those for the upgraded listings. This would allow our designer to only need to make tweaks to the listing.
I had to first convert the hundreds of form entries into a more exportable format, so I wrote a PHP script to convert each entry to one row per category in a MySQL database, marking the primary category, so we could export all for the digital flipbook, or just the primary category for the print issue.
The next challenge was to turn this into a usable XML export. I had to learn a lot about XML and how XML files can map to InDesign. I had our designer mock up a layout and name styles, including for spacers, and optional mages, and worked with her to perfect a small scale test. While working on that, I discovered a way to estimate the height of listings and force column breaks in approximately the right space, to save our designer time and allow us more time to sell ads and listings.
When it came to actually importing the listings, we ran into issues with the sheer amount of data—InDesign crashed repeatedly. So I had to chunk up the exports.
While we were revising this, I had an idea.
We could create a redirect script, collect basic data on clicks on digital flipbook, and alter the export script to build these links.
So I whipped up a simple proof of concept URL redirector, altered the export script to create the database entries for the redirector on export and retooled the export file to include the short URL. I refined the redirector as our staff tested, and build out the data collection mechanism and optimized the database.
Ultimately, the Buyer’s Guide proved useful and generated tons of click data to validate our digital audience, but we did not see a high enough ratio of upgrades to paid listings to repeat the product, but the time savings through my XML to InDesign export lead to a higher-than-expected profit margin on our work and we used smaller scale XML to InDesign scripts in the future.
Leave a Reply