Copy link to clipboard
Copied
After a full day of searching, I can't seem to find a software that can do this for me:
I have this slightly transparent png image:
And I want to be able to take a list of all (1000) of my articles headlines from my site, and batch add the text on this image. So that I can then have 1000 of these images all with different text on them that I can place on top of 1 background image in batch mode.
How can I do this?
Check this out:
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Check this out:
Copy link to clipboard
Copied
If I can understand your question then use Variables and Data Sets. Variable should be: Text Replacement and you can load text file with all 1000 headlines then to export 1000 files with different text (variable assigned to layer with text and loaded data set) and the rest of composition will be the same for all exported files. Please read this tutorial: Creating data-driven graphics in Photoshop
Copy link to clipboard
Copied
Thank you, I'll check this out. It seems to be what I'm after. There is also the other thing that I need to do which is, once I've created these images, I want to batch put all of them over the top of a background image. Is there any tutorial on that as well?
Copy link to clipboard
Copied
If I read that correctly, once you create your original images, you'd want to likely batch output (save) them as static images and then use the exact same data-driven variable technique you used to create the first ones.
Copy link to clipboard
Copied
After I create the variables, and I go to export them all like this: Export >>> Data Sets As Files
It only allows me to export them as PSD files. To do what I need to do in the next step, I'd need them all in PNG file format won't I?
So how can I "Batch Output" them all, like you said? (in PNG format I mean)
Copy link to clipboard
Copied
One would use Image Processor/Image Processor Pro scripts or perhaps even a batch action to automate the creation of the PNG files from the working PSD files.
Copy link to clipboard
Copied
Just to be clear, Image Processor script ships with Photoshop (File/Scripts/Image Processor) and the Image Processor Pro script is freely downloadable.
Copy link to clipboard
Copied
I do like the Image Processor as well - it saves you from having to make an action - but I'm just a bit more of a control freak, and like to specify my export settings for something like a PNG. @Stephen_A_Marsh's suggestion is faster though- if you don't need to alter any export settings.
Copy link to clipboard
Copied
To me, actions are far easier to make than scripts (i'm just averse to coding, when I can help it).
Unfortunately, my Quick Export doesn't work in an action (on my Mac - haven't checked on a Windows machine), so you'd create an action that Opens files and exports via the Save for Web- Legacy and choose the PNG settings you want. Then, record the Save option (you'll change the save to location in the next step. If you don't need transparency, you can just use Save As, and select the PNG format and Save.
Then, you'd go to File>Automate>Batch - Select your action. Choose the .psd file folder you want to convert, check all the boxes on that left side (so it can run without you being there). On the right, you'd choose a Save Destination and a method of naming. I find it very important to change Errors to Save to File, so it'll run through any errors and report back, instead of stopping.
Then you just hit "OK" and walk away...
For more information on making actions, if you need, you may want to check out Create actions in Adobe Photoshop
Copy link to clipboard
Copied
I'll give it a try and let you know how it goes.
Copy link to clipboard
Copied
I'll watch for updates. I wanted to do a video, but I'm sorry I can't right now...
Copy link to clipboard
Copied
By the way, before I try this, would there be a way to export the png images into separate folders?
What I mean is, for instance, say I've created one png with a headline over it for each article headline I have, what I'd like to do is export each one of those PNG files into a folder of its own, with the folder being named the appropriate article headline.
This would be a big help, because I wouldn't have to sort through THOUSANDS to get to the graphic I'm looking for, I'd just have to go into the right folder and search from there.
Is this possible?
Copy link to clipboard
Copied
Hi
I still dont understand why you would do this in Photoshop.
I do this all the time on websites, all I need to do is adding the headline (html box) using "position: absolute;" over my posts images.
Instant done deal and no images overload.
What kind of framework are you using for that website ??
Pierre
Copy link to clipboard
Copied
It's nothing to do with my website, it's nothing to do with anything you mentioned. I'm creating graphics for the many article headlines I have, so I can have many variations of graphics for each one. So that will result in thousands of graphics, so, being able to save the right graphics to the right folder would say a huge amount of time.
Copy link to clipboard
Copied
Hi
Ok, guess I miss this (bold) : take a list of all (1000) of my articles headlines from my site.
But, I still dont understand your end goal. (and yes automation using scripts and actions, could do this)
Pierre
Copy link to clipboard
Copied
Well yeah they are taken from my site, but I'm not going to be using them with my site. I'll be using them for something else.
Copy link to clipboard
Copied
I would approach this two ways:
1) Add metadata such as a keyword to each file, based on the Photoshop text layer metadata content
2) Automatically sort files into a directory/folder based on the Photoshop text layer metadata content
Both of these methods presume that there is only a single text layer and that you wish to use the TextLayerText rather than the TextLayerName. It is also presumed that there are no illegal filename characters in the text layer content.
To achieve both aims, I would use ExifTool. This can all be automated/batched from a single top level folder…
Add metadata such as a keyword:
exiftool -r '-subject+<XMP-photoshop:TextLayerText' '/Users/username/Desktop/inputfolder'
Automatically sort each file into a directory/folder based on metadata:
exiftool -r '-directory<${directory}/${XMP-photoshop:TextLayerText}' -d '%d' '/Users/username/Desktop/inputfolder'
NOTE: The previous command line codes are from the Mac, on Windows simply change the single straight quote/foot mark ' to straight double quote/inch marks " with the correct platform specific path to the top level folder. These commands will create backup copies of the original files, a command can be added to overwrite the originals once you have tested that all this works as intended.
SUMMARY: Save out the datasets to individual PSD files in a single top-level folder. Then use ExifTool to add keyword metadata for search purposes, then automatically move the files into new folders. Finally, run the Image Processor Pro script to create PNG files in the same folders as the PSD files.
Copy link to clipboard
Copied
Perhaps using the Keyword metadata field is not a good idea, the Description or Title entries probably makes more sense… so:
exiftool -r '-MWG:Description<XMP-photoshop:TextLayerText' '/Users/username/Desktop/inputfolder'
Copy link to clipboard
Copied
I have a new idea now. I don't want to save them to different folders, all I want to do now I realize is, export data sets as files, with the files being named the variable value.
It doesn't seem to be giving me the option to export them naming them the variable value, only the data set number etc.
Is there a way I can do this?
Copy link to clipboard
Copied
Sure, the ExifTool command to rename the PSD files based on the content of a single text layer would look like this (presuming no possibility of creating duped files or the need for adding sequential numbers to help create unique filenames):
exiftool -r '-filename<$XMP-photoshop:TextLayerText.%e' '/Users/username/Desktop/inputfolder'
Copy link to clipboard
Copied
Turns out I didn't need that ExifTool. For some reason Photoshop is now exporting the PSD files as the text layer values.
Copy link to clipboard
Copied
Yes, there are export options:
I had forgotten and did not check before posting the ExifTool suggestion, however it is good to know that there are multiple ways to the same end!
I would still recommend that you use ExifTool to batch embed metadata into each image to make the files more portable and to offer another search option.
Copy link to clipboard
Copied
I hadn't ever looked at ExifTool before, although I'd heard of it in the past. Thanks to your link, I was reading the documentation and one of it's "Features" is listed as "Decodes a riddle wrapped in a mystery inside an enigma"! That makes this a MUST HAVE!