Embedded Timeline Widget only displaying link

embeddedtimeline

#1

First time trying to use anything from Twitter, and I’m a bit confused as to what I actually need to pull tweets from a twitter account I just made. I’m currently building a website for a school project, and I made a fake company twitter account of which I’m trying embed the tweets into the site.

I’ve tried multiple ways, searched stack overflow, and the forum, but everyone who seems to have the same problem, their solution doesn’t do anything for me.

Currently I’m getting this.

I’ve tested across Chrome, Safari, and Firefox. They all display the same thing, with no errors in the console.

This is what i originally tried with only getting the ^ above result.

<a class="twitter-timeline" href="https://twitter.com/Protech_RI">Tweets by Protech_RI</a>
<script async src="//platform.twitter.com/widgets.js" charset="utf-8"></script>
<script>window.twttr = (function(d, s, id) {
    var js, fjs = d.getElementsByTagName(s)[0],
        t = window.twttr || {};
    if (d.getElementById(id)) return t;
    js = d.createElement(s);
    js.id = id;
    js.src = "https://platform.twitter.com/widgets.js";
    fjs.parentNode.insertBefore(js, fjs);

    t._e = [];
    t.ready = function(f) {
    t._e.push(f);
   };

    return t;
}(document, "script", "twitter-wjs"));</script>

Then I tried this, which was copy and past from twitter widget settings ( i edited the widget-id)

<a class="twitter-timeline"  href="https://twitter.com/search?q=%40Protech_RI" data-widget-id="7692937xxxx1167749">Tweets about @Protech_RI</a>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>

Now, could my issue be because I just created the account, and only have 1 tweet, which seems to not be registering in the widget display in my settings?

Although, when I was the https://publish.twitter.com/ trying to originally make it, it was actually displaying the twitter feed I had so far.

Anyone who can help me, or shed some light, would be much appreciated. Being new to this, the documentation is rather overwhelming, because i’m not sure if I’m supposed to be using my API keys somewhere, or if this is just a simple copy and paste sort of thing, that will display the tweets in an embedded div?

Thank you,
Ian


#2

A Twitter embedded timeline has two components: a link and the JavaScript needed to interpret the link. It looks like Twitter’s widgets JavaScript is not properly loading on your site.

View source of the website. Search for platform.twitter.com. Is the JavaScript code copy and pasted from publish.twitter.com on the page?

Are you running any ad blockers or other software which may interfere with loading the JavaScript?


#3

Thanks for the response. To the best of my knowledge, I never set up any ad-block extensions. Though after checking more, I do have security software + extensions that seem to have been the issue. Once I disabled some of the settings it works in Chrome and Safari.

I guess, this leaves me to my next question. Would this be a likely scenario for the majority of users visiting sites, with it not loading due to ad-block/security extensions? I’d like to use it, but I’d have to imagine most people are going to have something blocking the widget from loading correctly.

Thanks.


#4

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.