{"id":667,"date":"2009-06-16T16:34:52","date_gmt":"2009-06-16T20:34:52","guid":{"rendered":"http:\/\/cd34.com\/blog\/?p=667"},"modified":"2009-06-16T16:34:52","modified_gmt":"2009-06-16T20:34:52","slug":"flowplayer-org-and-red5","status":"publish","type":"post","link":"https:\/\/cd34.com\/blog\/webserver\/flowplayer-org-and-red5\/","title":{"rendered":"flowplayer.org and red5"},"content":{"rendered":"<p>Dozens of posts on the net reference using red5 with flowplayer for rtmp streaming, but, none give you precisely the code required.<\/p>\n<pre>\r\n&lt;!DOCTYPE html PUBLIC \"-\/\/W3C\/\/DTD XHTML 1.0 Transitional\/\/EN\"\r\n\t\"http:\/\/www.w3.org\/TR\/xhtml1\/DTD\/xhtml1-transitional.dtd\"> \r\n\t\r\n&lt;script src=\"flowplayer-3.1.1.min.js\"><\/script>\t\r\n\r\n&lt;style>\r\na.rtmp {\r\n\tdisplay:block;\r\n\twidth:640px;\r\n\theight:360px;\t\r\n\tmargin:25px 0;\r\n\ttext-align:center;\r\n}\r\n\r\na.rtmp img {\r\n\tborder:0px;\r\n\tmargin-top:140px;\r\n}\r\n&lt;\/style>\r\n\r\n&lt;a class=\"rtmp\" href=\"#\">\r\n&lt;img src=\"http:\/\/static.flowplayer.org\/img\/player\/btn\/showme.png\"  \/>\r\n&lt;\/a>\r\n\r\n&lt;script type=\"text\/javascript\">\r\n\r\n$f(\"a.rtmp\", \"flowplayer-3.1.1.swf\", { \r\n\t\t\r\n\tclip: { \r\n\t\tprovider: 'rtmp',\r\n\/\/ name of the .flv from \/webapps\/oflaDemo\/streams without the .flv\r\n                url: 'IronMan' \r\n\t}, \r\n\t\r\n\tplugins: {  \r\n\t  rtmp: {  \r\n\t\turl: '\/fprt\/flowplayer.rtmp-3.1.0.swf',\t\t\t\r\n\t\tnetConnectionUrl: 'rtmp:\/\/hostname\/oflaDemo'\r\n\t  } \r\n\t}     \r\n});\r\n&lt;\/script>\r\n<\/pre>\n<p>Make sure you have the following files:<\/p>\n<p>* flowplayer-3.1.1.swf<br \/>\n* flowplayer.controls-3.1.1.swf<br \/>\n* flowplayer.rtmp-3.1.0.swf<\/p>\n<p>If you receive the error:<\/p>\n<p>300: Player Initialization Failed: TypeError: Error #1009<\/p>\n<p>Then you are missing flowplayer.controls-3.1.1.swf from your directory.<\/p>\n<p>In the javascript, <\/p>\n<blockquote><p>netConnectionUrl: &#8216;rtmp:\/\/hostname\/oflaDemo&#8217;<\/p><\/blockquote>\n<p>needs to be set the hostname of your red5 server.<\/p>\n<blockquote><p>url: &#8216;IronMan&#8217;<\/p><\/blockquote>\n<p>needs to be set to the name of the .flv in the webapps\/oflaDemo\/streams directory without the .flv extension<\/p>\n<pre>\r\n\/usr\/lib\/red5\/webapps\/oflaDemo\/streams# ls -1 *.flv\r\nDarkKnight.flv\r\nIronMan.flv\r\non2_flash8_w_audio.flv\r\ntest.flv\r\n<\/pre>\n<div style=\"float:left;\">\n<div id=\"fb-root\"><\/div>\n<fb:like href=\"https:\/\/cd34.com\/blog\/webserver\/flowplayer-org-and-red5\/\" width=\"250\" send=\"false\" show_faces=\"false\" layout=\"button_count\" action=\"recommend\"><\/fb:like>\n<\/div><div style=\"clear:both;\"><\/div>","protected":false},"excerpt":{"rendered":"<p>Dozens of posts on the net reference using red5 with flowplayer for rtmp streaming, but, none give you precisely the code required. &lt;!DOCTYPE html PUBLIC &#8220;-\/\/W3C\/\/DTD XHTML 1.0 Transitional\/\/EN&#8221; &#8220;http:\/\/www.w3.org\/TR\/xhtml1\/DTD\/xhtml1-transitional.dtd&#8221;> &lt;script src=&#8221;flowplayer-3.1.1.min.js&#8221;> &lt;style> a.rtmp { display:block; width:640px; height:360px; margin:25px 0; text-align:center; } a.rtmp img { border:0px; margin-top:140px; } &lt;\/style> &lt;a class=&#8221;rtmp&#8221; href=&#8221;#&#8221;> &lt;img src=&#8221;http:\/\/static.flowplayer.org\/img\/player\/btn\/showme.png&#8221; \/> [&hellip;]<\/p>\n<div style=\"float:left;\">\n<div id=\"fb-root\"><\/div>\n<fb:like href=\"https:\/\/cd34.com\/blog\/webserver\/flowplayer-org-and-red5\/\" width=\"250\" send=\"false\" show_faces=\"false\" layout=\"button_count\" action=\"recommend\"><\/fb:like>\n<\/div><div style=\"clear:both;\"><\/div>","protected":false},"author":15,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[34],"tags":[46,47,45],"class_list":["post-667","post","type-post","status-publish","format-standard","hentry","category-webserver","tag-flash","tag-flowplayer","tag-red5"],"_links":{"self":[{"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/posts\/667","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/users\/15"}],"replies":[{"embeddable":true,"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/comments?post=667"}],"version-history":[{"count":1,"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/posts\/667\/revisions"}],"predecessor-version":[{"id":668,"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/posts\/667\/revisions\/668"}],"wp:attachment":[{"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/media?parent=667"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/categories?post=667"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cd34.com\/blog\/wp-json\/wp\/v2\/tags?post=667"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}