/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
var seleccionado = ""

var reproductorAudioPre = "<OBJECT ID='MediaPlayer' WIDTH='0' HEIGHT='0' style='visibility: hidden'"
    reproductorAudioPre += "classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95'  codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715'"
    reproductorAudioPre +="TYPE='application/x-oleobject'></OBJECT>"

var reproductorAudio = "<OBJECT ID='MediaPlayer'  WIDTH='290' HEIGHT='200'"
    reproductorAudio += "classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95'  codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715'"
       reproductorAudio +="standby='Cargando componentes Microsoft Windows Media Player...'"
       reproductorAudio +="TYPE='application/x-oleobject' VIEWASTEXT>"
       reproductorAudio +="<PARAM NAME='FileName' VALUE='mms://172.21.0.65/sciradio'>"
       reproductorAudio +="<PARAM NAME='AnimationatStart' VALUE='true'>"
       reproductorAudio +="<PARAM NAME='TransparentatStart' VALUE='true'>"
       reproductorAudio +="<PARAM NAME='AutoStart' VALUE='true'>"
       reproductorAudio +="<PARAM NAME='ShowControls' VALUE='true'>"
       reproductorAudio +="<PARAM NAME='Autosize' VALUE='true'>"
       reproductorAudio +="<PARAM NAME='ShowStatusBar' VALUE='true'>"
       reproductorAudio +="<embed TYPE='application/x-mplayer2'"
       reproductorAudio +="pluginspage='http://www.microsoft.com/isapi/redir.dll?prd=windows&sbp=mediaplayer&ar=Media&sba=Plugin&'"
       reproductorAudio +="SRC='mms://radio.presidencia.gub.uy/sciradio'"
       reproductorAudio +="ShowControls=1"
       reproductorAudio += "AutoStart=1"
       reproductorAudio += "Autosize=1"
       reproductorAudio += "ShowStatusBar=1"
       reproductorAudio += "Width='290'"
       reproductorAudio +="Height='200'>"
       reproductorAudio +="</embed></OBJECT>"

var reproductorCam1 = "<OBJECT ID='MediaPlayer' WIDTH='290' HEIGHT='200'"
    reproductorCam1 += "classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95'  codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715'"
       reproductorCam1 +="standby='Cargando componentes Microsoft Windows Media Player...'"
       reproductorCam1 +="TYPE='application/x-oleobject' VIEWASTEXT>"
       reproductorCam1 +="<PARAM NAME='FileName' VALUE='mms://radio.presidencia.gub.uy/sciradiowebcam1'>"
       reproductorCam1 +="<PARAM NAME='AnimationatStart' VALUE='true'>"
       reproductorCam1 +="<PARAM NAME='TransparentatStart' VALUE='true'>"
       reproductorCam1 +="<PARAM NAME='AutoStart' VALUE='true'>"
       reproductorCam1 +="<PARAM NAME='ShowControls' VALUE='false'>"
       reproductorCam1 +="<PARAM NAME='Autosize' VALUE='true'>"
       reproductorCam1 +="<PARAM NAME='ShowStatusBar' VALUE='true'>"
       reproductorCam1 +="<embed TYPE='application/x-mplayer2'"
       reproductorCam1 +="pluginspage='http://www.microsoft.com/isapi/redir.dll?prd=windows&sbp=mediaplayer&ar=Media&sba=Plugin&'"
       reproductorCam1 +="SRC='mms://radio.presidencia.gub.uy/sciradiowebcam1'"
       reproductorCam1 +="ShowControls=0"
       reproductorCam1 += "AutoStart=1"
       reproductorCam1 += "Autosize=1"
       reproductorCam1 += "ShowStatusBar=1"
       reproductorCam1 += "Width='290'"
       reproductorCam1 +="Height='200'>"
       reproductorCam1 +="</embed></OBJECT>"

var reproductorCam2 ="<OBJECT ID='MediaPlayer' WIDTH='187' HEIGHT='160'"
    reproductorCam2 += "classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95'  codebase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715'"
       reproductorCam2 +="standby='Cargando componentes Microsoft Windows Media Player...'"
       reproductorCam2 +="TYPE='application/x-oleobject' VIEWASTEXT>"
       reproductorCam2 +="<PARAM NAME='FileName' VALUE='mms://172.21.0.65/sciradiowebcam2'>"
       reproductorCam2 +="<PARAM NAME='AnimationatStart' VALUE='true'>"
       reproductorCam2 +="<PARAM NAME='TransparentatStart' VALUE='true'>"
       reproductorCam2 +="<PARAM NAME='AutoStart' VALUE='true'>"
       reproductorCam2 +="<PARAM NAME='ShowControls' VALUE='false'>"
       reproductorCam2 +="<PARAM NAME='Autosize' VALUE='true'>"
       reproductorCam2 +="<PARAM NAME='ShowStatusBar' VALUE='false'>"
       reproductorCam2 +="<embed TYPE='application/x-mplayer2'"
       reproductorCam2 +="pluginspage='http://www.microsoft.com/isapi/redir.dll?prd=windows&sbp=mediaplayer&ar=Media&sba=Plugin&'"
       reproductorCam2 +="SRC='mms://172.21.0.65/sciradiowebcam2'"
       reproductorCam2 +="ShowControls=1"
       reproductorCam2 += "AutoStart=1"
       reproductorCam2 += "Autosize=1"
       reproductorCam2 += "ShowStatusBar=1"
       reproductorCam2 += "Width='187'"
       reproductorCam2 +="Height='160'>"
       reproductorCam2 +="</embed></OBJECT>"

           function mostrar(sel){

                if (sel != seleccionado){
                    var elemento = document.getElementById('postview')
                    if (sel == 'a'){
                        elemento.innerHTML = reproductorAudio
                    }else if(sel == 'c1'){
                        elemento.innerHTML = reproductorCam1
                    }else{
                        elemento.innerHTML = reproductorCam2
                    }
                    seleccionado = sel
                }
            }

            function seleccionarAudio(){
                var radio = document.getElementById('radioAudio')
                radio.click()
            }

