Jump to:

796 Posts in 409 Topics by 304 members

Widgets

SilverStripe Forums » Widgets » TwitterWidgetPack - no hashtag displayed

Discuss SilverStripe Widgets.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1795 Views
  • borriej
    Avatar
    Community Member
    267 Posts

    TwitterWidgetPack - no hashtag displayed Link to this post

    Hello,

    Installed the TwitterWidgetPack into the CMS. Selected Profile widget. Saved. And it works.

    BUT:
    - When I hit the checkbox: 'display hashtag?' it doens't show the # or the word behind the hashtag.
    - When I disable the checkbox, the result is the same.

    Example:
    - When i twitter #test, it won't display anything in the widget on my twitterpage it looks correct.

    Any ideas?

  • borriej
    Avatar
    Community Member
    267 Posts

    Re: TwitterWidgetPack - no hashtag displayed Link to this post

    Ok i got an idea of the problem:

    the correct wat to display a twitter widget (according to the twitter website) is:

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

    The ouput of the SS TwitterWidgetPack is:

    <script src="http://widgets.twimg.com/j/2/widget.js"></script>
    <script>
    new TWTR.Widget({
    "version":2,"type":"profile","rpp":"10","interval":"600","width":"auto","height":"600","theme":{"shell":{"background":"#EAEAEA","color":"#000000"},"tweets":{"background":"#ffffff","color":"#000000","links":"#0099FF"}},"features":{"scrollbar":false,"loop":false,"live":false,"hashtags":false,"timestamp":true,"avatars":false,"behavior":"default"}}).render().setUser('usernameHere').start();
    </script>

    The php file with the code says:
       
    function WidgetSetupJSON() {
          $settings = $this->WidgetSetup();
          return Convert::raw2json($settings);
       }

    Question:
    - Is there a way to convert an array to version = 2, instead of "version"= 2

    thx

  • MartinPhone
    Avatar
    Community Member
    57 Posts

    Re: TwitterWidgetPack - no hashtag displayed Link to this post

    No, any text after a hashtag isn't displayed... Anyone know what's causing this?

    1795 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.