diff --git a/dist/sharetastic.js b/dist/sharetastic.js index 156d178..07758db 100644 --- a/dist/sharetastic.js +++ b/dist/sharetastic.js @@ -94,7 +94,7 @@ var Sharetastic = function () { twitter: { order: 2, name: 'Twitter', - href: 'http://twitter.com/home?status=' + this.generateTitle() + this.generateUrl(' - '), + href: 'https://twitter.com/intent/tweet?text=' + this.generateTitle() + this.generateUrl(' - '), icon: { width: 32, height: 32, @@ -178,7 +178,7 @@ var Sharetastic = function () { var exportOptions = $.extend(true, defaults, options); if (this.element.hasAttribute('data-tweet')) { - exportOptions.services.twitter.href = 'http://twitter.com/home?status=' + encodeURIComponent(this.element.getAttribute('data-tweet')); + exportOptions.services.twitter.href = 'https://twitter.com/intent/tweet?text=' + encodeURIComponent(this.element.getAttribute('data-tweet')); } return exportOptions; diff --git a/lib/javascript/index.js b/lib/javascript/index.js index c30e00f..d6318a6 100644 --- a/lib/javascript/index.js +++ b/lib/javascript/index.js @@ -76,7 +76,7 @@ class Sharetastic { twitter: { order: 2, name: 'Twitter', - href: `http://twitter.com/home?status=${this.generateTitle()}${this.generateUrl(' - ')}`, + href: `https://twitter.com/intent/tweet?text=${this.generateTitle()}${this.generateUrl(' - ')}`, icon: { width: 32, height: 32, @@ -160,7 +160,7 @@ class Sharetastic { const exportOptions = $.extend(true, defaults, options) if (this.element.hasAttribute('data-tweet')) { - exportOptions.services.twitter.href = `http://twitter.com/home?status=${encodeURIComponent(this.element.getAttribute('data-tweet'))}` + exportOptions.services.twitter.href = `https://twitter.com/intent/tweet?text=${encodeURIComponent(this.element.getAttribute('data-tweet'))}` } return exportOptions diff --git a/package.json b/package.json index 05118fb..650aa8c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "sharetastic", - "version": "2.0.7", + "version": "2.0.8", "description": "A simple jQuery social sharing plugin", "main": "dist/sharetastic.js", "style": "dist/sharetastic.sass",