Embedding Tweets

OK. That makes sense. He did re-tweet something similar shortly afterwards so he must have deleted the first one.

 
Last edited by a moderator:
Just FYI, it appears that you can only embed two tweets per post. That's probably fine but just in case the question comes up.

 
I don't think that has been brought up. That is a "live" feed of any tweets that meet a certain criteria. So far, we've just been embedding specific tweets in a post.

For example:


Is that what you're asking?

 
I was thinking live Twitter. I wasn't sure what it was called.

Have a bunch of them in their recruiting dudes, newspaper guys, etc

Could we place them inside forums?

Or just on the front page?

 
I see the problem. What needs to be done is to create two new XML files for import that "read" the mobile portion of the URL, and strips it out. Let me give it a try and see what I can come up with. May be this weekend before I can complete them and test them. Dave is much better with XML than I am, but I don't know when he'll see this. If he does, he can probably whip them out pretty quickly.

 
I don't know how the plugin works, but would it be possible/easier to modify the existing "read" and just make the test work for either mobile.twitter or just twitter?

 
I don't think so. The original mod had two XML files - one when the word "status" is used in the URL and one when the word "statuses" is used. I took that to mean that trying both in the same XML would not work.

 
https://mobile.twitter.com/MikeMatya/status/604097779850428416

Hmmm...that didn't work. Left the mobile in. Let's try it without formatting.

Nope - that didn't do it either. Here's the XML for the "desktop", followed by my XML for the "mobile":

<?xml version="1.0" encoding="utf-8"?>
<mediatagexport>
<mediataggroup>
<mediatag>
<mediatag_name>Tweet Embed Status</mediatag_name>
<mediatag_match>https://twitter.com/{1}/status/{2}</mediatag_match>
<mediatag_replace><![CDATA[<blockquote class="twitter-tweet"><a href="https://twitter.com/$1/status/$2"></a></blockquote><script async src="//platform.twitter.com/widgets.js" charset="utf-8"></script>]]></mediatag_replace>
</mediatag>
</mediataggroup>
</mediatagexport>

And now mine:

Code:
<?xml version="1.0" encoding="utf-8"?>
<mediatagexport>
  <mediataggroup>
    <mediatag>
      <mediatag_name>Mobile Tweet Embed Status</mediatag_name>
      <mediatag_match>[URL="https://mobile.twitter.com/%7B1%7D/status/%7B2%7D"]https://mobile.twitter.com/{1}/status/{2}</mediatag_match>[/URL]
      <mediatag_replace><![CDATA[<blockquote class="twitter-tweet"><a href="[URL="https://twitter.com/%241/status/%242"]https://twitter.com/$1/status/$2[/URL]"></a></blockquote><script async src="//platform.twitter.com/widgets.js" charset="utf-8"></script>]]></mediatag_replace>
    </mediatag>
  </mediataggroup>
</mediatagexport>
 
Last edited by a moderator:
Back
Top