display variable in console for troubleshooting

i have a jsp page ( with jstl ) ; i have some veriable which i want to debug(show) in my console
what do i use to display the variables in the console so i troubleshoot the problem

Thanks

royalcyberAsked:
Who is Participating?
 
objectsCommented:
try:

<%
   System.out.println(var);
%>
0
 
CEHJCommented:
If you're just debugging, why not just print the variable to the page?
0
 
cincin77Commented:
also you can log your messages:

<%
application.log("this is the message.");
%>

The log file is defined in server.xml  for Tomcat.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.