Use a text overlay along with a remote image.

raymondcamden
raymondcamden Member Posts: 8

I'm using this URL to load in a remote image, and it works fine (removing https to stop the post from rendering it):

res.cloudinary.com/raymondcamden/image/fetch/https://maps.googleapis.com/maps/api/staticmap%3Fcenter=51.477222,0&zoom=14&size=400x400&key=AIzaSyCA0y7kh6V8poL-faDyVf3TpnLDNf9XtQY

When I try to add a text layer, like so:

res.cloudinary.com/raymondcamden/image/l_text:Arial_80:Flowers/fl_layer_apply/fetch/https://maps.googleapis.com/maps/api/staticmap%3Fcenter=51.477222,0&zoom=14&size=400x400&key=AIzaSyCA0y7kh6V8poL-faDyVf3TpnLDNf9XtQY

I get a broken image. Checking the headers, I see this error: Invalid value l_text:Arial_80:Flowers for parameter type

Answers

  • colbyfayock
    colbyfayock Member, Cloudinary Staff Posts: 8

    /fetch/ is the delivery type and must always come after the asset type (image)

    so you'd want it to look like:

    .../image/fetch/l_text:Arial_80:Flowers/fl_layer_apply/https...
    
    https://res.cloudinary.com/raymondcamden/image/fetch/l_text:Arial_80:Flowers/fl_layer_apply/https://maps.googleapis.com/maps/api/staticmap%3Fcenter=51.477222,0&zoom=14&size=400x400&key=AIzaSyCA0y7kh6V8poL-faDyVf3TpnLDNf9XtQY