Topic-icon Need to Format Twitter Posts

Active Subscriptions:

None
8 years 3 months ago - 8 years 3 months ago #56610 by webdevtim
Thanks Alex, you answered everything. Well mostly

I see there are a few people not too happy with Twitter's decision to have card displayed closed.

I will add the short title and short URL to each article so that the posts to twitter are at least differentiated.

After adding the short Title and short URL with the tags:
{SCOpenGraph url=http://911to.org/behind-smoke-curtain/}{SCOpenGraph title=Behind the Smoke Curtian}

I see that twitter:title, og:title: and og:url are as follows.
<meta name="twitter:title" content="Behind the Smoke Curtain"/><meta property="og:title" content="Behind the Smoke Curtain"/>
<meta property="og:url" content="http://911to.org/behind-smoke-curtain/"/>

But after deleting and reposting the article to Twitter, I still see the long URL and the long Title.

I checked again today and the short URL and the short Title are the only entries for og:url, twitter:title and og:title on the page. Twitter still shows the long title when validating the page and long title and long url after deleting and reposting the article to Twitter. This means that Twitter has a cached version of the card stored somewhere and that Cache needs to be purged.

Do you have any idea where I go to purge the Twitter card cache? Obviously validator doesn't do the trick like the Face book re-scrape feature does. Twitter isn't very transparent in this area.
Last edit: 8 years 3 months ago by webdevtim.
The topic has been locked.
Support Specialist
8 years 3 months ago #56624 by alzander
Check out the below post from Twitter for how to test updates to your card data. It sounds like they re-cache the data around every week, but there is a (slightly cumbersome) method to double-check the changes will be properly picked up on the next scan:
dev.twitter.com/cards/troubleshooting#outdated

I hope that helps,
Alex
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago - 8 years 3 months ago #56625 by webdevtim
Thanks Alex, I will try that. Hope I don't get stuck with a bit.ly URL in the Card that takes a week to get purged.

I am going through and adding the short URLs to .htaccess and corresponding short URL and Title tags to each of the articles, and I am realizing that I need a decent re-direct manager if I am going to be doing this for all the content on the website. Have any suggestions? Yes I know there is the basic redirect manager that comes with Joomla 3, but anything a little more automated?

Here was a suggestion for an interim fix:

Card information is visible when expanding the tweet. If you'd like to include the article's photo pre-expanded in your timeline, you can attach the original photo to the tweet when posting. This would mean your tweet has both the URL to your article and an automatically created pic.twitter.com URL. This is not ideal, but our product team is aware of this use case and is always working to improve the user experience. If you have any questions, please do not hesitate to follow up.


Guide to Uploading Media
Last edit: 8 years 3 months ago by webdevtim.
The topic has been locked.
Support Specialist
8 years 3 months ago #56630 by alzander
I don't have a good suggestion. sh404SEF is the somewhat de-facto SEF extension and you can setup short urls and redirects to other longer URLs. However, it uses a bit of resources, can cause conflicts with other extensions and is a bit kludgy. It does work though and we use it on this site. There's lots of good talk about better SEF routing coming to Joomla in an upcoming release in 2016 and, at that time, I'll happily ditch sh404. Of course, then I'll have to setup redirects from all the URLs that sh404SEF created by default to the ones that Joomla will create... which creates a little bit of lock-in.. and another reason to avoid not using it, if you can.

Regarding the interim fix, I saw that as well.. it's not terrible, but it creates 2 images for the Tweet.. one in the Tweet and another in the summary, which is redundant, but at least works.

I hope that helps, somewhat, address your question, even if it doesn't really answer anything.

Thanks,
Alex
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56632 by webdevtim
Thanks, Alex, but as it has already been mentioned cards come pre-expanded on Mobile devices and having the og:image and attaching the image would cause two images to show up on mobile devices, which wouldn't look so nice. And if Twitter suddenly decides to have cards pre-expanded on Twitter Home pages, then suddenly those Tweets would also have two images; not only not ideal, but downright ugly. I will add comment text to the top of each tweet and already have the short URLS added to .htaccess and the url: tags added to the article to uniquely identify each Tweet and will just wait for Twitter to change their code. I will create a K2 item template to add the SCOpenGraph tags be added at the top of each article, or any other content that will need to be filled in as part of the regular work-flow. Might add {SCOpenGraph description=…} tags as well so that I can have better 140 character descriptions of the articles.

But any way, I think we have gone as far as we can on this thread, so thank you a heap for all the help. I gave a review on the JED that reflects what I think about your just incredibly awesome support.
The topic has been locked.
Support Specialist
8 years 3 months ago #56636 by alzander
I'm glad it sounds like you have a plan forward.

and will just wait for Twitter to change their code

While I hope they do it quickly, if you'll notice, some of the links and answers I posted above are from 2014.. so I'm not sure how soon, if ever, you should expect them to change things. It's a battle of brevity (which Twitter is definitely focused on) vs promotional/rich content showing and who knows which way they'll start to lean in the future.

But any way, I think we have gone as far as we can on this thread, so thank you a heap for all the help. I gave a review on the JED that reflects what I think about your just incredibly awesome support.

Thank you so much! It's very appreciated.

All the best,
Alex
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago - 8 years 3 months ago #56637 by webdevtim
Just wanted to say that Twitter Isn't using short URL from the og:url tag. They are using the fully formed URL from the actual page on the site. If it comes from bit.ly as they suggested the bit.ly short URL bit.ly/1nsivgA is used. But if I comes from www.911truthoutreach.org/557-news-releas...nd-universities.html, then that gets used even if I have a redirect
RedirectMatch 301 ^(.*)/911truthoutreach-debate-challenge/?$ https://www.911truthoutreach.org/557-news-releases/374-debate-challenge-to-colleges-and-universities.html
and {SCOpenGraph url=http://911to.org/911truthoutreach-debate-challenge/} is added at the top of the article and I see og:url=http://911to.org/911truthoutreach-debate-challenge/ in the source.

Also people where I am will be complaining if our tweets go to Twitter in brief format that requires a click to see the full post when other's tweets are arriving in full form.

Will have to figure out how to make the Twitter suggestion of embedding the image work, since you don't think they will be changing their format any time soon.

Sorry I guess I spoke a bit too soon about having taken this as far as we can go for now.

Maybe this is the reason Twitter is using long URL:
<div style="position: relative; top:0px; left:0px; z-index: 99;" class="scsocialbuttons box_count"><div class="sourcecoast share twitter sc_twittershare"><a href="http://twitter.com/share" class="twitter-share-button" data-url="https://www.911truthoutreach.org/557-news-releases/433-the-stand-up-for-truth-campaign-ignores-9-11.html" data-count="vertical" data-dnt="false">Tweet</a></div><div class="sourcecoast plusone google sc_gplusone"><div class="g-plusone" data-annotation="bubble" data-size="tall" data-href="https://www.911truthoutreach.org/557-news-releases/433-the-stand-up-for-truth-campaign-ignores-9-11.html" data-recommendations="true" data-callback="plusone_callback"></div></div>
Even though:
<meta property="og:url" content="http://911to.org/stand-up-for-truth-ignores-911/"/>
Is present in the source.

And this bring up one more thing, how do I get everything to use the short URL?
Last edit: 8 years 3 months ago by webdevtim.
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56661 by webdevtim
This seems to be a never ending story. but how does AE911Truth get to have light box pop up in their Twitter Tweets. How can I implement this as well. I used to maintain the website for these people bu got frustrated and walked away. I really don't want their material looking better than mine; they decided to use big box, I decided to use Open Source.

Here are the screen shots from Twitter:



The topic has been locked.
Support Specialist
8 years 3 months ago #56687 by alzander

They are using the fully formed URL from the actual page on the site. If it comes from bit.ly as they suggested the bit.ly short URL bit.ly/1nsivgA is used.

Twitter owns Bit.ly. I wouldn't be surprised if they give it preference and show it only as the shortened URL.

Maybe this is the reason Twitter is using long URL:

You are correct. The Twitter button is using Joomla's page URL. There's not going to be a way to automatically set the short URL though. You'd need to stop using the JFBCContent plugin for automatically inserting the Tweet button and instead use our EasyTags in each article to set the short URL for each button, like:
{SCFacebookLike href=http://site.com/short-url}
{SCTwitterTweet href=http://site.com/short-url}
Since each short-url is unique, there's just not a way to have our automated share button set it.

The Open Graph URL tag I sent you above won't work for Twitter. I didn't realize this before as I thought we set a URL tag for Twitter cards as well, but looking through their documentation, there is no such URL tag like there is for Open Graph:
dev.twitter.com/cards/markup

This seems to be a never ending story. but how does AE911Truth get to have light box pop up in their Twitter Tweets. How can I implement this as well.

When you click a tweet, it displays in a lightbox popup. This happens for your tweets as well. When yours pops up, I see the full summary and image from your tweets. I'm not sure where it's not working for you here. The main difference is that they have set the image in the tweet itself and not using a link to their site... however, when popped up, Tweets in both streams have a similar look and feel to me.

Thanks,
Alex
The topic has been locked.
Active Subscriptions:

None
8 years 3 months ago #56692 by webdevtim
Thanks, Alex. I will have to weigh my options here and decide if I want to have to add all these tags to each article. There would be no automated way to do this as the short URL for each article would have to be created when the article is posted; don't think AI is quite that sophisticated yet.

I looked at Twitter's suggestion for attaching the image to the post, but when I clicked on the link for more information, I got a 404 page not found error from Twitter. If you have a link to a page that describers this process, please send it along.
The topic has been locked.