Html embutido no java

alfinete

Power Member
Código:
package LEIN.BUSCA;

public class busca extends principal.SuperModulo
{

    public String nomeDeModulo()
    {
        return ("Busca");
    }

    public String servicosDisponiveis()
    {
        return ("busca, buscaporutilizador");
    }

    public String paginaHTML(String pagina, String subpagina, String username, int numParametros, String[] nomeParametros, String[] valorParametros)
    {

        String s = "";
        if (subpagina.equals("") || subpagina.equals("busca"))
        {
            s = "<html>" +
            "<TITLE>" + nomeDeModulo() + "</TITLE>" +
            "<link rel=\"STYLESHEET\" type=\"text/css\" href=\"teste2.css\" />"+
            "<script language=\"JavaScript\" type=\"text/javascript\">" +
            "function webSearch() {" +
              "if (document.busca.web.selectedIndex==0)" + " { self.frames[\"results\"].location.href=\"http://www.google.com/search?btnG=Google+Search&q=\"+document.busca.queryText.value.replace(\" \",\"+\"); }" +
              "if (document.busca.web.selectedIndex==1)" + " { self.frames[\"results\"].location.href=\"http://search.yahoo.com/search?p=\"+document.busca.queryText.value.replace(\" \",\"+\"); }" +
              "if (document.busca.web.selectedIndex==2)" + " { self.frames[\"results\"].location.href=\"http://www.altavista.com/web/results?pg=q&what=web&fmt=.&q=\"+document.busca.queryText.value.replace(\" \",\"+\"); }" +
              "if (document.busca.web.selectedIndex==3)" + " { self.frames[\"results\"].location.href=\"http://www.google.com/search?btnG=Google+Search&q=\"+document.busca.queryText.value.replace(\" \",\"+\")+\" site:.weblei.info\"; }" +
            "}" +
            "</script>" +
            "</head>" +
            "<body>" +
            "<form name=\"busca\">" +
            "<div align=\"left\">" +
                "<select name=\"web\" style=\"font-size: 10pt\">" +
                    "<option value=\"0\" selected>Google</option>" +
                    "<option value=\"1\">Yahoo!</option>" +
                    "<option value=\"2\">Altavista</option>" +
                    "<option value=\"3\">Pesquisa Local</option>" +
                "</select>" +
                "<input type=\"text\" size=\"34\" onFocus=select(); name=\"queryText\"  style=\"font-size: 11pt\" />" +
                "<input name=\"button\" type=\"button\" style=\"font-size: 11pt\" onClick=\"webSearch()\" value=\"Procurar\" /></td>" +
        "</div>" +
    "</form>" +

    "<iframe name=results src=\"\" frameborder=0 width=830 height=600 scrolling=auto></iframe>" +
    "</body>" +
    "</html>";


        } return s;
    }
}

agradecia que me dicessem se esta linha :

"<link rel=\"STYLESHEET\" type=\"text/css\" href=\"teste2.css\" />"+

no code acima descrito está bem em termos de sintaxe.

obrigado
 
Back
Topo