<< Home

No SEF URL?

Use this forum for issues related to TriniTronic's Nice Article Tweets Plugin.

Moderator: jamesSBT

No SEF URL?

Postby dex » Tue Dec 13, 2011 7:05 pm

Hi

I am running Joomla 1.7.2 with Nice Tweets 2.24. Using native Joomla SEF URLs. Site is http://devel.dailytradingreport.com

NB. There's .htaccess security - user:dex, pwd: dex on this site.

When an auto-tweet is posted (with or without shortl URLs) it's not using the sef url. See https://twitter.com/dex_tp

e.g. Link is http://devel.dailytradingreport.com/ind ... Itemid=470
where i would expect
http://devel.dailytradingreport.com/blo ... az-tweet-5

I followed the advice in this post : viewtopic.php?f=5&t=330 but to no avail.

Can you offer any further advice please?

Many thanks
Dex
dex
Tropos
Tropos
 
Posts: 14
Joined: Tue Aug 16, 2011 7:36 pm

Re: No SEF URL?

Postby Michael » Tue Dec 13, 2011 7:30 pm

Hi Dex,

It used to be that Twitter would automatically shorten any raw URL that got posted. They used to use bit.ly to do the shortening. However, that was a long time ago. I don't think they do that anymore.

Out of curiosity, is there a reason that you don't want to shorten your URLs? I mean, Joomla SEF URLs can get really long and they eat up that precious tweet character count.

One point worth mentioning, is that once the user clicks the URL on Twitter and is sent to your site, Joomla will automatically convert the non-SEF URL to the SEF version of the URL.

The extension simply asks Joomla for the article URL, so, I will have to look into how (or if) the extension would be able to ask Joomla for an SEF URL to send in a tweet.

~ Best regards
Contributed by Michael Babcock
User avatar
Michael
Cosmos
Cosmos
 
Posts: 2478
Joined: Thu Aug 14, 2008 12:30 am

Re: No SEF URL?

Postby dex » Tue Dec 13, 2011 8:18 pm

Hi Michael

Beg pardon, of course I DO want to use short URLs. I just want them to go thru to my SEF URL not the longhand version.

This is the bit that isnt working: "Joomla will automatically convert the non-SEF URL to the SEF version of the URL". Cant quite see why, I'd just assumed we were passing the long version to twitter, so that's why.

Ideally we'd have an SEF URL converted to a short URL, but i would also settle for anything that returns to the correct SEF URL in Joomla.

Thanks for your attention. :)

Dex
dex
Tropos
Tropos
 
Posts: 14
Joined: Tue Aug 16, 2011 7:36 pm

Re: No SEF URL?

Postby Michael » Tue Dec 13, 2011 8:27 pm

Hi Dex,

I understand now. I will need to look into this matter more and see if there is a solution that I can come up with for you.

I had a root canal earlier today, so I think I am calling it quits for now. But will pick your issue up tomorrow.

~ Best regards
Contributed by Michael Babcock
User avatar
Michael
Cosmos
Cosmos
 
Posts: 2478
Joined: Thu Aug 14, 2008 12:30 am

Re: No SEF URL?

Postby dex » Wed Dec 14, 2011 9:18 pm

Hope your teeth OK :)
dex
Tropos
Tropos
 
Posts: 14
Joined: Tue Aug 16, 2011 7:36 pm

Re: No SEF URL?

Postby Michael » Thu Dec 15, 2011 4:03 pm

Hi Dex,

I just wanted to let you know that I haven't forgotten about you. I am feeling better, and now trying to schedule a bit of time for your request. I am hoping that I will be able to add an option to the plugins parameters to use SEF URLs.

~ Best
Contributed by Michael Babcock
User avatar
Michael
Cosmos
Cosmos
 
Posts: 2478
Joined: Thu Aug 14, 2008 12:30 am

Re: No SEF URL?

Postby dex » Thu Dec 15, 2011 9:08 pm

Thanks Michael

top effort by you, esp so close to the holidays!
much appreciated

Dex
dex
Tropos
Tropos
 
Posts: 14
Joined: Tue Aug 16, 2011 7:36 pm

Re: No SEF URL?

Postby Michael » Tue Dec 20, 2011 1:27 pm

Hey Dex,

I originally thought that I was going to be able to make quick work of your request. But now after a number of hours researching and fiddling with the extension code set, I am starting to believe that it may not be possible.

I am going to keep looking into this for awhile longer, before I call it quits. I just wanted to give you a quick update, as to my progress, or lack there of.

~ Merry Christmas
Contributed by Michael Babcock
User avatar
Michael
Cosmos
Cosmos
 
Posts: 2478
Joined: Thu Aug 14, 2008 12:30 am

Re: No SEF URL?

Postby dex » Tue Dec 20, 2011 3:51 pm

Thanks for the heads up and for your investigations and effort.
Have a good break

Dex
dex
Tropos
Tropos
 
Posts: 14
Joined: Tue Aug 16, 2011 7:36 pm

Re: No SEF URL?

Postby Michael » Tue Dec 27, 2011 2:28 pm

Hi Dex,

After a lot of research and even more trial and error, I can't seem to get Joomla to give me the SEF URLs for the tweets. If you are familiar with PHP, and would like to give it a whirl, I would be happy to point you to the correct area to alter in the extension's scripts.

~ Best regards
Contributed by Michael Babcock
User avatar
Michael
Cosmos
Cosmos
 
Posts: 2478
Joined: Thu Aug 14, 2008 12:30 am

Re: No SEF URL?

Postby dex » Wed Jan 04, 2012 4:33 pm

Hi Michael

Ah well thanks so much for trying. Perhaps yes if you could give the location of the code, I will also take a look.

thanks
Dex
dex
Tropos
Tropos
 
Posts: 14
Joined: Tue Aug 16, 2011 7:36 pm

Re: No SEF URL?

Postby Michael » Thu Jan 05, 2012 1:11 pm

Hi Dex,

You're very welcome.

To change the link creation process, open the file found here joomla_directory/plugins/system/nicearticletweets/nicearticletweets.php.

Look for a bit of code like the following snippet around line 162.
Code: Select all
      if ($r['inc_link'] == 1){
               require_once(JPATH_SITE.DS.'components'.DS.'com_content'.DS.'helpers'.DS.'route.php');
               //$url = ' '.JURI::root().ContentHelperRoute::getArticleRoute($article->id, $article->catid, $article->sectionid);
               $url = ' '.JURI::root().ContentHelperRoute::getArticleRoute($article->id, $article->catid);
               //$url = ' '.JRoute::_(ContentHelperRoute::getArticleRoute($item->slug, $item->catslug));;
               
               if($r['shorten'] == 1){ //tinyurl


You can ignore the commented out bits, e.g. "//$url = ' '.JURI::root()" They are stay overs from earlier versions. You can simply remove them if you like.

~ All best regards
Contributed by Michael Babcock
User avatar
Michael
Cosmos
Cosmos
 
Posts: 2478
Joined: Thu Aug 14, 2008 12:30 am


Return to Joomla: Nice Article Tweets

Who is online

Users browsing this forum: No registered users and 1 guest