Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2012-04-01 10:27:01

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,909
Website

[forum] Embed tweets in conversations

It would be nice (and should be easy) to be able to embed tweets in forum posts when somebody would like to add one in context of a topic.

We do this in the magazine, for example (scroll down).

Twitter details here.

Basically, there’s a script to add in the head of the template. Then all anyone has to do is add a raw tweet link, like these (no Textile formatting), and the actual tweet generates in its place. Really, really good for cross-channel communication when tweets are relevant to a discussion.

Offline

#2 2012-04-02 07:01:46

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,323
Website Mastodon

Re: [forum] Embed tweets in conversations

Destry wrote:

Then all anyone has to do is add a raw tweet link … and the actual tweet generates in its place.

The documentation you linked to says something very different (make oEmbed request, then render and cache result, etc.).

Where did you get your information from?

Offline

#3 2012-04-02 07:52:03

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,909
Website

Re: [forum] Embed tweets in conversations

wet,

My information was just recapping how it works in the magazine.

But I realize now, after looking at the magazine code again, I gave the wrong link before. This one is what should work, theoretically: embedtweet.com. It’s what we’re using on the mag.

You add this in the head section:

<script language="javascript" src="http://embedtweet.com/javascripts/embed_v2.js"></script>

Then just add any tweet URL in copy and it’s replaced with the tweet.

Twitter has a simple embed tweet (instructions) process, but I don’t think that method will work here because of the reliance on HTML.

Offline

#4 2012-04-02 08:01:34

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,909
Website

Re: [forum] Embed tweets in conversations

Another correction on the tweet use…

The tweet URL does need to be added (Textile is fine) using this construction: "url":url.

Last edited by Destry (2012-04-04 08:04:11)

Offline

Board footer

Powered by FluxBB