JSP (Java Server Page) - Obtener Información del SO

 
Vista:

Obtener Información del SO

Publicado por pablitux (9 intervenciones) el 24/01/2005 17:18:47
Podría ayudarme alguien en como implantar la función getProperty("os.name") en un JSP. Ya probe con :
<%@page import="java.lang.*"%>
<html><body>
<%= new getProperty("os.name") %>
</body>
</html>
y me da un error en la compilación que dice:
-------------------------------------------
compile-single-jsp:
init:
deps-jar:
compile:
Compiling 1 source file to /home/postmaster/WebApplication1/build/generated/classes
/home/postmaster/WebApplication1/build/generated/src/org/apache/jsp/index_jsp.java:67: cannot resolve symbol
symbol : class getProperty
location: class org.apache.jsp.index_jsp
out.print( new getProperty("os.name") );
^
1 error
/home/postmaster/WebApplication1/nbproject/build-impl.xml:249: The following error occurred while executing this line:
/home/postmaster/WebApplication1/nbproject/build-impl.xml:241: The following error occurred while executing this line:
/home/postmaster/WebApplication1/nbproject/build-impl.xml:92: Compile failed; see the compiler error output for details.
BUILD FAILED (total time: 7 seconds)
------------------------------

gracias
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder