Keyword

Tiny URL not working on 'Tweet this to your followers'

More
13 years 11 months ago #73527 by dsa787
It works for me too. Thank you Devsmi!

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73528 by devsmi
I just changed your pass to the same as your username. try again

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73529 by devsmi
Remember. when Twitter removes the old version of their site for good and makes the "new version" the default..you mighthave to change back

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73530 by NosyWeb
Thanks for your help devsmi.

Therefore, I have the same problem with a '+' in between the words.

Rishona Campbell said:

Sure...it's www.rishonan.net devsmi said:I had no problems when testing this myself. Could I see your site ?

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73531 by devsmi
Ok yes I see it. off the top of my head I have no clue where that comes from, I will try to make some free time to look into it

 

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73532 by yaksushi
Yes the fix works but I am also getting the titles displayed with "+" instead of spaces

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73533 by Mary Jezierski
Replied by Mary Jezierski on topic Tiny URL not working on 'Tweet this to your followers'
I can't log in to your site either. Still awaiting activation email. :-(

devsmi said:
I just changed your pass to the same as your username. try again

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73534 by devsmi
marco, registering on my site is not sending out any personal information. only an email and username that you make up. Is that too much to ask in return for my time spent on this fix, offered to you for free?

It seems that the reason this happends is because twitter implemented their new homepage. If you click the button to use their old page again then this works just like before with no problem..But now with the new page there is a redirect in there. My fix is only going to be temporary because once twitter makes the new page the default and only one..things should work like normal again :) Although maybe somebody from k2 team can fix it for now

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73535 by Mary Jezierski
Replied by Mary Jezierski on topic Tiny URL not working on 'Tweet this to your followers'
Hello devsmi,

Thanks for your help with registration on your site. I was able to get in and applied the fix.

The fix works great, but the url is not shortened. :-(

Re: the '+' symbol, I changed "urlencode" to "urldecode", which replaces the plus sign with a space.

 

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73536 by Rishona Campbell
Replied by Rishona Campbell on topic Tiny URL not working on 'Tweet this to your followers'
Hi Mary!

 

Thanks so much for that fix to remove the '+'. Works great!

 

Also my URL does come up shortened. I enabled Tiny URL on the backend.Mary Jezierski said:

Hello devsmi,

Thanks for your help with registration on your site. I was able to get in and applied the fix.

The fix works great, but the url is not shortened. :-(

Re: the '+' symbol, I changed "urlencode" to "urldecode", which replaces the plus sign with a space.

 

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73537 by Mary Jezierski
Replied by Mary Jezierski on topic Tiny URL not working on 'Tweet this to your followers'
My bad... I had "Enable TinyURL integration for 'Tweet this' link" in the K2 parameters turned off. All is good now!

Thanks again!

Mary Jezierski said:

Hello devsmi,

Thanks for your help with registration on your site. I was able to get in and applied the fix.

The fix works great, but the url is not shortened. :-(

Re: the '+' symbol, I changed "urlencode" to "urldecode", which replaces the plus sign with a space.

 

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73538 by devsmi
Good Job Mary I didnt even think of that :)

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73539 by Fernando Nunes
Replied by Fernando Nunes on topic Tiny URL not working on 'Tweet this to your followers'
$item->twitterURL = 'twitter.com/home/?status='.urlencode('Reading @'.$params->get('twitterUsername').' '.$item->title.' '.$itemURLForTwitter);

 

to

 

$item->twitterURL = 'twitter.com/share?text='. urlencode( $params->get('twitterUsername') ).'&url=' . $itemURLForTwitter;

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73540 by Chris Valius
This doesn't work.. and when I don't do anything I still get + signs in the description.

Fernando Nunes said:
$item->twitterURL = 'twitter.com/home/?status='.urlencode('Reading @'.$params->get('twitterUsername').' '.$item->title.' '.$itemURLForTwitter);

 

to

 

$item->twitterURL = 'twitter.com/share?text='. urlencode( $params->get('twitterUsername') ).'&url=' . $itemURLForTwitter;

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73541 by Fernando Nunes
Replied by Fernando Nunes on topic Tiny URL not working on 'Tweet this to your followers'
go to: components\com_k2\views\item\view.html.php and view.raw.php

 

find: if ($params->get('itemTwitterLink') && $params->get('twitterUsername')) { ...

 

and replace function with:

 

if ($params->get('itemTwitterLink') && $params->get('twitterUsername')) {                        $itemURLForTwitter = $item->absoluteURL;                        if($params->get('tinyURL')) {            $ch = curl_init();            $timeout = 5;            curl_setopt($ch, CURLOPT_URL,'tinyurl.com/api-create.php?url='.$item->absoluteURL);            curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $timeout);            curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);            $itemURLForTwitter = curl_exec($ch);            curl_close($ch);            }                        $item->twitterURL = 'twitter.com/share?text='. urlencode( $params->get('twitterUsername') . ' '. $item->title ).'&url=' . $itemURLForTwitter;        }

 

You can check whether your hosting supports you curl by phpinfoSorry for English ...

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73542 by Chris Valius
This fixed it. Sorry it was at the bottom and did not notice.

Mary Jezierski said:
Hello devsmi,

Thanks for your help with registration on your site. I was able to get in and applied the fix.

The fix works great, but the url is not shortened. :-(

Re: the '+' symbol, I changed "urlencode" to "urldecode", which replaces the plus sign with a space.

 

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73543 by B_Dark
all good but the don't link the name of your site tweeter account with "@" before the twitterUsername

Fernando Nunes said:
go to: components\com_k2\views\item\view.html.php and view.raw.php

 

find: if ($params->get('itemTwitterLink') && $params->get('twitterUsername')) { ...

 

and replace function with:

 

if ($params->get('itemTwitterLink') && $params->get('twitterUsername')) {                        $itemURLForTwitter = $item->absoluteURL;                        if($params->get('tinyURL')) {            $ch = curl_init();            $timeout = 5;            curl_setopt($ch, CURLOPT_URL,'tinyurl.com/api-create.php?url='.$item->absoluteURL);            curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $timeout);            curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);            $itemURLForTwitter = curl_exec($ch);            curl_close($ch);            }                        $item->twitterURL = 'twitter.com/share?text='. urlencode( $params->get('twitterUsername') . ' '. $item->title ).'&url=' . $itemURLForTwitter;        }

 

You can check whether your hosting supports you curl by phpinfoSorry for English ...

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73544 by B_Dark
something like that "via @myusername" the only thing that post right now with  this fix is is username and after the title and the link of twitter

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73545 by Fernando Nunes
Replied by Fernando Nunes on topic Tiny URL not working on 'Tweet this to your followers'
Twitter API

 

You can do a variety of ways ... just follow the API. It is somewhat customizable. How do you want?

Please Log in or Create an account to join the conversation.

More
13 years 11 months ago #73546 by B_Dark
item title | twitter link via @username

Fernando Nunes said:
Twitter API

 

You can do a variety of ways ... just follow the API. It is somewhat customizable. How do you want?

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum