This support forum is no longer in use. Please use the Cloudinary Community at https://community.cloudinary.com/ to receive assistance from other members of the community and from Cloudinary's support team. For account-specific questions or if you believe that you've encountered a bug, please contact the Cloudinary team directly via the "submit a request" option on this support site.

Upload Image Fail: [Error: ENAMETOOLONG: name too long,

Comments

2 comments

  • Official comment
    Avatar
    Danny Valentine

    Hey. Thanks for getting in touch.

    I'm afraid we don't support directly uploading svg files in this way, however, if you base64 encode the SVG, the upload should be successful.

    To test, you can base64 encode everything from <svg> to </svg>, set your data variable to "data:image/svg+xml;base64," + base64_encoded_svg, and then upload with resource_type:'image' as an optional parameter.

    I put together a quick example here on repl.it that you can fork and test for yourself.

    If you have any questions, feel free to reply here or raise a support ticket with us.

    Thanks,
    -Danny

     

    Comment actions Permalink
  • Avatar
    linleiqin

    Can not upload this svg data,

    call back :[Error: ENAMETOOLONG: name too long, open.....

    Please HELP!!

    0
    Comment actions Permalink

Post is closed for comments.