0

我在 JSF 2 中开发了一个网站。但是,如果我尝试在 Google Chrome 中做同样的事情,那么一页“陈列室”在 Internet Explorer 中会出现异常,一切运行正常。关于这个例外,我不能多说,因为我真的对此一无所知。这就是我向你们展示的。

当我点击“Lâmpada”(在英语中的意思是灯)时会发生异常。在这里,您可以远程打开/关闭灯。正如我所说的一切正常,整个网站,甚至在 IE 中。只是页面“陈列室”给出了这个错误。

异常图像

编辑:

我的showroom.xhtml页面:

        <h:form id="form_supervisory">
            <h:panelGrid columns="1">
                <p>
                    <APPLET CODE="YawApplet.class" ARCHIVE="YawApplet.jar" CODEBASE="http://valterhenrique.dyndns.info:8081/" WIDTH="645" HEIGHT="485">
                      <param name="Host" value="valterhenrique.dyndns.info" />
                      <param name="Port" value="8081" />
                      <param name="Zoom" value="true" />
                    </APPLET>
                  </p>

                <h:commandButton value="Lâmpada" action="#{supervisoryc.light}" styleClass="button-5" >
                    <f:ajax execute="@form" render="@none" />
                </h:commandButton>
            </h:panelGrid>
        </h:form>

该小程序仅用于流式传输我的网络摄像头,我使用 Yawcam。

豆子:

@ManagedBean(name="supervisoryc")
@SessionScoped
public class SupervisoryControl implements Serializable {
    private static final long serialVersionUID = -2313043518176548344L;

    public void light(){
        Client client = new Client();
        client.send("valterhenrique.dyndns.info", "lamp");
    }

}

socket班级:

public class Client {

    public void send(String ip, String message){


        Socket s = null;  
        PrintStream ps = null;  

        try{  
            s = new Socket(ip, 7000);  
            ps = new PrintStream(s.getOutputStream());  
            ps.println(message);  

        }catch(IOException ioe){  
            throw new RuntimeException(ioe.getMessage());  

        }finally{  

            try{  
                s.close();  

            }catch(IOException e){}  

        }  

    }  
}

这就是我的应用程序工作所需的全部内容。知道为什么会这样吗?

4

0 回答 0