[FIX] website: prevent URL from being encoded twice
Before this commit, the twitter share (intents) would encode the URL twice. The URL on the tweet would then be broken. Eg: https%3A%2F%http://2Fwww.odoo.com%2Fforum...
This commit is contained in:
@@ -856,7 +856,7 @@ registry.socialShare = Animation.extend({
|
||||
var hashtags = ' #'+ document.title.split(" | ")[1].replace(' ','') + ' ' + this.hashtags; // company name without spaces (for hashtag)
|
||||
var social_network = {
|
||||
'facebook': 'https://www.facebook.com/sharer/sharer.php?u=' + url,
|
||||
'twitter': 'https://twitter.com/intent/tweet?original_referer=' + url + '&text=' + encodeURIComponent(title + hashtags + ' - ' + url),
|
||||
'twitter': 'https://twitter.com/intent/tweet?original_referer=' + url + '&text=' + encodeURIComponent(title + hashtags + ' - ') + url,
|
||||
'linkedin': 'https://www.linkedin.com/shareArticle?mini=true&url=' + url + '&title=' + encodeURIComponent(title),
|
||||
'google-plus': 'https://plus.google.com/share?url=' + url,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user