For single posts and pages, I would like to add certain rel
attributes to all the images on the contained therein added with the “Add Image” functionality on the edit screen.
The attribute would be rel="lightbox[post id]"
What function would I filter to accomplish this most effectively?
image_send_to_editor
The
rel="whatever"
attribute is only for search engines. If you consider to make your content “better” for spiders, crawlers and such, take a look at this list first.