Skip to content

Commit 11eabb7

Browse files
authored
Merge pull request #3142 from catchpoint/fix_email_share
fix email share
2 parents ef772d0 + 1815432 commit 11eabb7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

www/include/social_meta_vars.inc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
require_once __DIR__ . '/../common_lib.inc';
44
require_once __DIR__ . '/../common.inc';
55

6-
$pageURI = urlencode('https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']);
6+
$pageURI = 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
77
// NOTE: if you'd like a page to include a screenshot for social sharing, specify $useScreenshot = true above the head include.
88
// Also, for page-specific screenshot css tweaks, add a screenshot class to that page's body class
99
$screenshotURI = CreateUrlVariation($pageURI, "screenshot=1");
@@ -13,5 +13,5 @@ $socialImage = isset($useScreenshot) ? "https://wpt-screenshot.netlify.app/" . u
1313
$socialTitle = isset($socialTitle) ? $socialTitle : "WebPageTest";
1414
$socialDesc = isset($socialDesc) ? $socialDesc : "View this on WebPageTest.org...";
1515
$emailSubject = "View this on WebPageTest!";
16-
$tweetURI = 'https://twitter.com/intent/tweet?text=' . urlencode($socialDesc) . '&url=' . urlencode($pageURI) . '&via=realwebpagetest';
17-
$emailURI = 'mailto:?subject=' . rawurlencode(htmlspecialchars_decode($emailSubject)) . '&body=' . rawurlencode(htmlspecialchars_decode($socialDesc) . ' %0D%0A ') . $pageURI;
16+
$tweetURI = 'https://twitter.com/intent/tweet?text=' . urlencode($socialDesc) . '&url=' . $pageURI . '&via=realwebpagetest';
17+
$emailURI = 'mailto:?subject=' . rawurlencode(htmlspecialchars_decode($emailSubject)) . '&body=' . rawurlencode(htmlspecialchars_decode($socialDesc) . " \n ") . $pageURI;

0 commit comments

Comments
 (0)