Skip to content
This repository has been archived by the owner on Sep 18, 2021. It is now read-only.

Commit

Permalink
Merge branch 'master' of github.com:twitter/twitter-text-js
Browse files Browse the repository at this point in the history
  • Loading branch information
keita committed May 18, 2012
2 parents 695d53e + 66b07dd commit 7b9986c
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions twitter-text.js
Expand Up @@ -497,9 +497,11 @@ if (typeof twttr === "undefined" || twttr === null) {
precedingEllipsis: displayUrl.match(/^…/) ? "…" : "",
followingEllipsis: displayUrl.match(/…$/) ? "…" : ""
};
$.each(v, function(index, value) {
v[index] = twttr.txt.htmlEscape(value);
});
for (var k in v) {
if (v.hasOwnProperty(k)) {
v[k] = twttr.txt.htmlEscape(v[k]);
}
}
// As an example: The user tweets "hi http://longdomainname.com/foo"
// This gets shortened to "hi http://t.co/xyzabc", with display_url = "…nname.com/foo"
// This will get rendered as:
Expand Down

0 comments on commit 7b9986c

Please sign in to comment.