What's the equivalent of C++'s "#ifdef #endif" macro in JSP?

614 Views Asked by At

What's the equivalent of C++'s #ifdef #endif macro in JSP? Is there such thing in JSP?

I want to conditionally include files in one JSP or another. Reason for doing that is because I have a nested setup (nested jquery ui tabs). I prefer to include files in the outermost layer for the "release" version. But for the "debug" version, I prefer to include file in the inner layers so I can debug individual pages. I'm using <%@ include ... %> to include files.

If it's possible, how would you implement that? I think JSP include action (<jsp:include>) would work, but that's probably slower than JSP include directives.

Thanks.

1

There are 1 best solutions below

1
On

There is no direct equivalent. Check this thread. And probably this can shed some light as well.