diff options
author | Wojciech Polak <polak@gnu.org> | 2013-03-31 23:50:50 +0200 |
---|---|---|
committer | Wojciech Polak <polak@gnu.org> | 2013-03-31 23:50:50 +0200 |
commit | 60e0d3542efe9e49b61aa82d2e49a5e561e2a0b6 (patch) | |
tree | fb6dfad8acd077c070c85db22332365dbe04bb3f | |
parent | 62915434c5576331e28393d6ca61da18d49dce7d (diff) | |
download | glifestream-60e0d3542efe9e49b61aa82d2e49a5e561e2a0b6.tar.gz glifestream-60e0d3542efe9e49b61aa82d2e49a5e561e2a0b6.tar.bz2 |
Add instagram.com support.
-rw-r--r-- | filters/expand.py | 1 | ||||
-rw-r--r-- | static/js/glifestream.js | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/filters/expand.py b/filters/expand.py index a345ad7..90f6963 100644 --- a/filters/expand.py +++ b/filters/expand.py @@ -98,6 +98,7 @@ def shortpics(s): s = re.sub(r'http://(www\.)?(twitpic\.com)/(\w+)', __sp_twitpic, s) s = re.sub(r'http://lockerz\.com/s/(\d+)', __sp_lockerz, s) s = re.sub(r'http://(instagr\.am)/p/([\w\-]+)/?', __sp_instagram, s) + s = re.sub(r'http://(instagram\.com)/p/([\w\-]+)/?', __sp_instagram, s) s = re.sub(r'http://(yfrog\.com)/(\w+)', __sp_yfrog, s) s = re.sub(r'http://(www\.)?brizzly\.com/pic/(\w+)', __sp_brizzly, s) s = re.sub(r'http://(www\.)?flickr\.com/([\w\.\-/]+)', __sp_flickr, s) diff --git a/static/js/glifestream.js b/static/js/glifestream.js index c6ed501..6e2d2ae 100644 --- a/static/js/glifestream.js +++ b/static/js/glifestream.js @@ -1234,6 +1234,10 @@ href = 'http://api.plixi.com/api/tpapi.svc/imagefromurl?size=big&url=http://lockerz.com/s/' + RegExp.$1; type = 'image'; } + else if (href.match (/instagram\.com\/p\/([\w\-]+)\/?/)) { + href = 'http://instagram.com/p/'+ RegExp.$1 +'/media/?size=l'; + type = 'image'; + } else if (href.match (/instagr\.am\/p\/([\w\-]+)\/?/)) { href = 'http://instagr.am/p/'+ RegExp.$1 +'/media/?size=l'; type = 'image'; |