27 September 2012

Original (Functional) Twitter Embed Codes.


Twitter changed their embed code around, and now you have to 'apply' to get a widget, and as you know I'm reluctant to make changes.  So here are the original codes you can modify which actually work.

Original Script for Profile Code

<script src="http://widgets.twimg.com/j/2/widget.js"></script><br />
<script>
new TWTR.Widget({
  version: 2,
  type: 'profile',
  rpp: 4,
  interval: 30000,
  width: 250,
  height: 300,
  theme: {
    shell: {
      background: '#333333',
      color: '#ffffff'
    },
    tweets: {
      background: '#000000',
      color: '#ffffff',
      links: '#4aed05'
    }
  },
  features: {
    scrollbar: false,
    loop: false,
    live: false,
    behavior: 'all'
  }
}).render().setUser('nameofuser').start();
</script>

No @ necessary to preface 'nameofuser'
Modify height, width, and color any way you want it. 

Original Script for Search Code


<script charset="utf-8" src="http://widgets.twimg.com/j/2/widget.js"></script>
<script>
new TWTR.Widget({
  version: 2,
  type: 'search',
  search: '#NameOfSearch',
  interval: 10000,
  title: 'Title Of Search',
  subject: 'Subject:',
  width: 250,
  height: 1000,
  theme: {
    shell: {
      background: '#ffffff',
      color: '#000000'
    },
    tweets: {
      background: '#ffffff',
      color: '#444444',
      links: '#1985b5'
    }
  },
  features: {
    scrollbar: false,
    loop: true,
    live: true,
    behavior: 'default'
  }
}).render().start();
</script>

You can play around with all the "true/false" stuff in there. 
Also, Width, height, colors, and more are interchangeable.  


Original Script for List Code



<script charset="utf-8" src="http://widgets.twimg.com/j/2/widget.js"></script>
<script>
new TWTR.Widget({
  version: 2,
  type: 'list',
  rpp: 30,
  interval: 30000,
  title: 'Title Of List',
  subject: 'Subject Of List',
  width: 'auto',
  height: 600,
  theme: {
    shell: {
      background: '#000000',
      color: '#ffffff'
    },
    tweets: {
      background: '#000000',
      color: '#ffffff',
      links: '#ff6666'
    }
  },
  features: {
    scrollbar: true,
    loop: false,
    live: true,
    behavior: 'all'
  }
}).render().setList('username', 'name-of-list').start();
</script>


name-of-list must be case-sensitive with spaces separated by hyphens.  
username is the name of the user, minus the @
title of list appears on top in small letters
subject of list appears below in large letters







No comments:

Post a Comment