comparison src/sync.coffee @ 5:af9f5b94c019

receive tweets
author Mathias Gebbe <mgebbe@intevation.de>
date Fri, 06 Jun 2014 14:42:28 +0200
parents f352c74a6a5b
children 2123f355ab68
comparison
equal deleted inserted replaced
4:f352c74a6a5b 5:af9f5b94c019
116 if not attachment.image? 116 if not attachment.image?
117 parsed += "<br><img src='" + attachment.image.url + "'></img>" 117 parsed += "<br><img src='" + attachment.image.url + "'></img>"
118 118
119 callback null, parsed 119 callback null, parsed
120 120
121 if network is 'twitter'
122
123 parsed = "<img src='" + post.user.profile_image_url + "'></img> <a href='https://twitter.com/account/redirect_by_id/" + post.user.id + "'>" + post.user.name + "</a> <a href='https://twitter.com/" + post.user.screen_name + "/status/" + post.id_str + "'> schreibt </a> via " + network + " am " + post.created_at + ":<br><br>" + post.text
124 _.each post.entities.media, (attachment) ->
125 parsed += "<br><img src='" + attachment.media_url + "'></img>"
126 callback null, parsed
127
121 return 128 return
122 129
123 130
124 sync = () -> 131 sync = () ->
125 132
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)