When using a shorturl you sometimes need to help the Tweet Button identify
the correct URL to count. To do this add the full, long URL as the
data-counturl parameter of the button. More information on this is in our
Tweet Button documentation:
    http://dev.twitter.com/pages/tweet_button#using-shorturl

The data-expanded-url is something added during the presentation processing
of twitter.com - it has no affect on the URL counting system or click
destination.

Ken: can you give me an example of one of the URLs which causes the 404s you
describe.

Best,
@themattharris
Developer Advocate, Twitter
http://twitter.com/themattharris


On Tue, Feb 15, 2011 at 8:38 PM, ctrand <ctr...@gmail.com> wrote:

> Does anyone have any thoughts on the issue Ken and I are looking at?
>
> On Feb 15, 11:04 pm, "Ken D." <k...@cimas.ch> wrote:
> > I have a possibly related problem.
> >
> > We also use an inhouse shortener that returns a 301 redirect, but
> > Twitterbot misinterprets the shortened URLs. The usual search engine
> > bots follow the redirect correctly, as far as I can tell.
> >
> > Each tweet results in a frenzy of 404s from API users who have
> > received the incorrect URL. Mousing over the shortened URL on
> > Twitter.com shows the incorrect URL in the title tooltip. Fortunately
> > for now, it seems we are not subject to t.co wrapping so the original,
> > correct short URLs can be clicked by Twitter.com users.
> >
> > The incorrectly interpreted URL is always the same. We've set it up to
> > redirect to our home page so all is not lost.
> >
> > Any ideas what could be going on here?
> >
> > Thanks, Ken
> >
> > On Feb 14, 2:04 am, ctrand <ctr...@gmail.com> wrote:
> >
> > > Any ideas on this one guys?
> >
> > > On Feb 10, 4:06 pm, ctrand <ctr...@gmail.com> wrote:
> >
> > > > Hello,
> >
> > > > I have a bunch of shortened urls which are resolved/redirected to
> full
> > > > urls by my webapp.
> >
> > > > e.g.
> >
> > > >http://dealush.com/sale/2wml
> >
> > > > resolves to
> >
> > > >
> http://dealush.com/shopping-sales/2wml/sydney-sale-8-off-at-catwalk-w...
> >
> > > > When I tweet the short URL, sometimes the data-expanded-url attribute
> > > > is populated for the url and when I mouseover it I can see the full
> > > > url. However sometimes it is not populated, and there is no data-
> > > > expanded-url attribute at all!
> >
> > > > I am wondering if anyone can shed some light onto why it would be so.
> >
> > > > I am also thinking that this is affecting the counters on my tweet
> > > > buttons, as tweets that do have an URL with the data-expanded-url
> > > > attribute give a +1 for the counter, and those that do not have a
> data-
> > > > expanded-url don't.
> >
> > > > Does something need to happen for the data-expanded-url value to
> > > > populate? Or perhaps there something wrong with some of my URLS?
> >
> > > > Note: THe example URL above does have a data-expanded-url value.
> >
> > > > Thanks in advance,
> >
> > > > Carl
> >
> > > > PS - Please let me know if you need any additional information from
> me
> > > > and it will be forthcoming!
>
> --
> Twitter developer documentation and resources: http://dev.twitter.com/doc
> API updates via Twitter: http://twitter.com/twitterapi
> Issues/Enhancements Tracker:
> http://code.google.com/p/twitter-api/issues/list
> Change your membership to this group:
> http://groups.google.com/group/twitter-development-talk
>

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk

Reply via email to