Add your Twitter Username to the Twitter widget on the sidebar

Notice: Do not copy and past the code below into your .php files.  This code has been formatted through html.  Please type in the actual code into your .php file.  This also helps you learn how to code html and you’ll be a CSS master in no time  :)

1. Open the sidebar.php (works for all themes)

2. Locate the “twitter-feed” div. (I highlighted my username in red for your convenience)

<div class=”twitter-feed”>
<h2>What I’m up to…</h2>
<ul id=”twitter_update_list”></ul>
<script type=”text/javascript” src=”http://twitter.com/javascripts/blogger.js”></script>
<script type=”text/javascript” src=”http://twitter.com/statuses/user_timeline/JunLoayza.json?callback=twitterCallback2&amp;count=1″></script>
<div class=”follow-on-twitter”>
<a rel=”nofollow” href=”">Follow me on Twitter</a>
</div>
</div>

3. Replace my Twitter username (JunLoayza) with yours

<script type=”text/javascript” src=”http://twitter.com/statuses/user_timeline/AddYourUsernameHere.json?callback=twitterCallback2&amp;count=1″></script>

4. Now you will want to add your twitter URL to the “Follow me on Twitter” link.  The following code is listed in blue above:

<a rel=”nofollow” href=”http://Twitter.com/AddYourUsernameHere“>Follow me on Twitter</a>

5. The final code should like this:

<div class=”twitter-feed”>
<h2>What I’m up to…</h2>
<ul id=”twitter_update_list”></ul>
<script type=”text/javascript” src=”http://twitter.com/javascripts/blogger.js”></script>
<script type=”text/javascript” src=”http://twitter.com/statuses/user_timeline/AddYourUsernameHere.json?callback=twitterCallback2&amp;count=1″></script>
<div class=”follow-on-twitter”>
<a rel=”nofollow” href=”http://Twitter.com/AddYourUsernameHere“>Follow me on Twitter</a>
</div>
</div>

6. Save the file

If you have any questions about this, feel free to ask me in the comment section.  Thanks!

RSS feed | Trackback URI

Comments »

No comments yet.

Name (required)
E-mail (required - never shown publicly)
URI
Your Comment (smaller size | larger size)
You may use <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> in your comment.

Trackback responses to this post