Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix broken image-link when og:image contains "&" (e.g. Google Maps) #1627

Merged
merged 1 commit into from
Dec 11, 2015
Merged

Conversation

jgerle
Copy link

@jgerle jgerle commented Dec 10, 2015

When sending a link to Google Maps the preview image is broken. Background: The link to the image is grabbed from the target page from the meta.og:image element - which contains several "&amp" instead of "&" in case of GM.

@engelgabriel
Copy link
Member

Thanks for the PR @jgerle

Can you please provide an example for us to test before I merge this?

@engelgabriel
Copy link
Member

Like this:

https://www.google.com.br/maps/@51.5111633,-0.136791,14z/data=!4m2!6m1!1szPCL6A0Ftp8k.kQgTj0s5kSuo?hl=en

The meta.og:image is:

https://maps.google.com/maps/api/staticmap?sensor=false&center=51.5111633%2C-0.136791&zoom=14&size=256x256&language=en&client=google-maps-frontend&signature=hFBWctfgMEpwmiIQrolMOAOisxs

engelgabriel added a commit that referenced this pull request Dec 11, 2015
fix broken image-link when og:image contains "&" (e.g. Google Maps)
@engelgabriel engelgabriel merged commit b023db6 into RocketChat:develop Dec 11, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants