Skip to content
Browse files

tweeking

  • Loading branch information...
1 parent 8d4e8d2 commit 9b6dee9ada23d36e38936e79847af33a12fe1f3c @chrismatthieu committed Jul 4, 2011
Showing with 5 additions and 4 deletions.
  1. +4 −3 lib/tss_web_server.rb
  2. +1 −1 views/search.erubis
View
7 lib/tss_web_server.rb
@@ -80,11 +80,12 @@ class TSSWebServer < Sinatra::Base
end
get("/ustream") do
+ # key=339100083E900F21974AE0A065A54BF2
channel = params[:channel]
info = JSON.load(
- open("http://api.ustream.tv/json/channel/%s/getInfo" % CGI.escape(channel)){ |f| f.read() })
- @channel_id = info["results"]["id"]
- query = info["results"]["socialStream"]["hashtag"]
+ open("http://api.ustream.tv/json/channel/%s/getInfo?key=339100083E900F21974AE0A065A54BF2" % CGI.escape(channel)){ |f| f.read() })
+ @channel_id = info["results"]["id"] rescue "cnn"
+ query = info["results"]["socialStream"]["hashtag"] rescue "cnn"
return search(query, :ustream, false)
end
View
2 views/search.erubis
@@ -33,7 +33,7 @@
function onLoad() {
initialize();
// supress left column
-onCloseLeftButtonClick();
+// onCloseLeftButtonClick();
}
</script>

0 comments on commit 9b6dee9

Please sign in to comment.
Something went wrong with that request. Please try again.