Tech Note: Embedded Tweets in Comments and Pages

New Twitter integration features
LGF • Views: 28,310

We have some new features to announce, designed to make it much simpler to place embedded tweets from Twitter in comments and LGF Pages.

All you have to do to insert an embedded tweet is paste in the URL of the tweet’s ‘Details’ page at Twitter. For example, here’s the page for my tweet about the previous article.

You get to these individual tweet pages at Twitter by clicking the time/date on any tweet, or by expanding it (by clicking inside it) and then clicking the ‘Details’ link.

When your comment or Page is posted, the URL of the tweet will be automatically transformed by the LGF Blog Engine (through the magic of regular expressions and Twitter’s oEmbed API) into the HTML code that shows the full text of the tweet. This HTML code can then be further transformed into the actual Twitter-formatted embedded tweet, with links for following, replying, retweeting, etc.

Unfortunately, that final step can only happen at page load time; the Twitter API doesn’t have a method of rendering the embedded tweet dynamically yet. This means that if you post a comment through our Ajax system, you won’t see the final Twitter-formatted tweet — but you will see the full text of the tweet with a credit line and links to the author, so it’s still useful. You’ll see the final embedded tweet the next time you reload the entire page.

For LGF Pages authors, there’s another nice feature. When you use the LGF Pages bookmarklet on any Twitter details page, the Pages posting form will open up with the code for the embedded tweet already inserted in the editing box — you don’t even have to copy or paste anything.

Jump to top

Create a PageThis is the LGF Pages posting bookmarklet. To use it, drag this button to your browser's bookmark bar, and title it 'LGF Pages' (or whatever you like). Then browse to a site you want to post, select some text on the page to use for a quote, click the bookmarklet, and the Pages posting window will appear with the title, text, and any embedded video or audio files already filled in, ready to go.
Or... you can just click this button to open the Pages posting window right away.
Last updated: 2016-01-01 10:29 am PST
LGF User's Guide RSS Feeds Tweet

Help support Little Green Footballs!

Subscribe now for ad-free access!Register and sign in to a free LGF account before subscribing, and your ad-free access will be automatically enabled.

Donate with
PayPal
Square Cash Shop at amazon
as an LGF Associate!
Recent PagesClick to refresh
House Votes to Back Two-State Solution in Middle East WASHINGTON (CN) — Rebuking President Donald Trump, the House of Representatives on Friday passed a resolution supporting a two-state solution to the Israeli-Palestinian conflict. Smoke rises from Gaza City on May 5, 2019, after Israel launched over 350 airstrikes ...
Thanos
1 day, 13 hours ago
Views: 253 • Comments: 0 • Rating: 0
Tweets: 1 • Share to Facebook
California Urged to Rethink 40 Years of ‘Piecemeal’ Freshwater Protections Ultimately the drought had relatively minor impacts on most urban Californians who suddenly had to do things like let their lawns go brown or – gasp – ask for water while dining out. But under the surface, 18 fish ...
Thanos
2 days, 9 hours ago
Views: 320 • Comments: 0 • Rating: 0
Tweets: 1 • Share to Facebook
VULFPECK /// Back Pocket (Live at Madison Square Garden)VULFPECK /// Back Pocket (Live at Madison Square Garden)buy on vinyl → vuuulf.com
Thanos
2 days, 14 hours ago
Views: 356 • Comments: 0 • Rating: 0
Tweets: 3 • Share to Facebook
EVGENY POBOZHIY QUINTET - Stranger Thoughts Evgeny Pobozhiy Quintet - Stranger Thoughts Evgeny Pobozhiy - guitar, compositionAnton Chekurov - saxNikolai Sidorenko - keysSergey Korchagin - bassAlexander Kulkov - drumsRecorded live @ Blues-minus studio, MoscowViktor Farafontov - sound engineerAndrey Galyamin - videoSergey Gasparyan - mixing2019 ...
Thanos
3 days, 23 hours ago
Views: 407 • Comments: 0 • Rating: 0
Tweets: 0 • Share to Facebook
#Thegreatpoolpondconversion - 191201 It was an ‘easy’ unchallenging weekend. While low key, we got a lot done. We worked on the upper wall, setting and pounding in the 72 bags we dropped in last week. There are now two courses done completely ...
Dangerman (misuser of the sarc tag)
4 days, 8 hours ago
Views: 354 • Comments: 0 • Rating: 4
Tweets: 0 • Share to Facebook
Marvel Studios’ Black Widow - Official Teaser Trailer Marvel Studios' Black Widow is in theaters May 1, 2020. ► Subscribe to Marvel: bit.ly► See the poster: marvel.com► Learn more: marvel.com Follow Marvel on Twitter: ‪@marvelLike Marvel on Facebook: ‪facebook.com For even more news, stay tuned to:Tumblr: ‪marvelentertainment.tumblr.comInstagram: ...
Thanos
5 days, 4 hours ago
Views: 523 • Comments: 0 • Rating: 0
Tweets: 1 • Share to Facebook
Commanded to Love Some reflections on the the crucial role emotion can play in keeping us stuck in abuse — and in recovery and immunisation. You can support the channel at: patreon.com--opening quote:‘feel crime’ — the crime of feeling an emotion that ...
Thanos
5 days, 6 hours ago
Views: 2,793 • Comments: 0 • Rating: 0
Tweets: 1 • Share to Facebook
Sony Overtakes Nikon to Become Number Two Camera Company Behind Canon ony has been aggressively coming after the camera market for several years now, and it seems their efforts are paying off, as they have now overtaken Nikon for the second position behind Canon. Nikkei is reporting that Sony is ...
Thanos
1 week ago
Views: 792 • Comments: 2 • Rating: 2
Tweets: 2 • Share to Facebook
The Weeknd - Blinding Lights (Audio) Official audio for The Weeknd "Blinding Lights" - available everywhere now: theweeknd.co ►Subscribe to The Weeknd on YouTube: theweeknd.co ►Follow The Weeknd:@theweekndfacebook.cominstagram.comtheweeknd.comSubscribe to YouTube Music: theweeknd.co ►"Blinding Lights" Lyrics:I been tryna callI’ve been on my own for long enoughMaybe ...
Thanos
1 week ago
Views: 757 • Comments: 0 • Rating: 0
Tweets: 1 • Share to Facebook
Tuxedo - Get the Money (Feat. CeeLo Green) Official audio of Tuxedo's "Get The Money (Feat. CeeLo Green)" Stream now: tuxedo.lnk.to Subscribe to the official Tuxedo Channel here: smarturl.it Lyrics:Get the moneyAll the timeYeah we want itDollar signs We’ll pile it up to the skyTen miles highNo ...
Thanos
1 week ago
Views: 793 • Comments: 0 • Rating: 0
Tweets: 1 • Share to Facebook