Skip to content
This repository was archived by the owner on Mar 11, 2021. It is now read-only.
This repository was archived by the owner on Mar 11, 2021. It is now read-only.

oEmbed URL with international characters leads to 400 #477

Description

@garmoncheg

Problem: Meta oEmbed url is generated with wrong data in an international page. E.g.: https://www.documentcloud.org/documents/7203159-Joaquín-El-Chapo-Guzmán-Appeal.html

So example oEmbed url leading to 400 is generated like so:
https://www.documentcloud.org/api/oembed.json?url=https%3A%2F%2Fwww.documentcloud.org%2Fdocuments%2F7203159-Joaqu%C3%ADn-El-Chapo-Guzm%C3%A1n-Appeal.html

I believe the solution should be similar to URL encoding this variable or there is something in underlying data logic maybe.
<%= @oembeddable_resource.oembed_url %>

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions