[fix bug 1082208] Support media files and CDN.

`.format` is preferred over `%` when possible.