jsp

Are Java web frameworks really worth the hassle?

I'm relatively new to Java programming (About 2 years) but not to web development. I started out with HTML and ASP (pre .NET), and have recently started messing with J2EE. I feel like I have a good grasp of JSP/Servlets (I find them to be similar to ASP) and have recently begun working with JSF and Facelets. Although I can see why peo...

How Do I make dynamic-attributes Work in JSP Tag Files?

So according to my JSP reference book, as well as every other reference I can find on the web, I'm supposed to be able to do something like: <%@ tag dynamic-attributes="dynamicAttributesVar" %> and then when someone uses an attribute that I didn't define in an attribute directive, I should be able to access that attribute from the "dy...

Where is the "work" directory located for a Tomcat instance running in Eclipse?

In Eclipse you can configure numerous servers to run inside the IDE, including Tomcat. Depending on your Tomcat configuration, at some point in the life cycle of a webapp your JSP files will get compiled into servlets. These new servlet .class files are stored in the %TOMCAT_HOME%/work directory along with the .java intermediate file cre...

What tactics can I use to prevent users from discovering what language a website is written in?

So, if you are writing a website using Java and JSP's and didn't want users to know what language you written it in. What techniques would you use? ...

How to use the "application" object in a Servlet?

If we are coding a JSP file, we just need to use the embedded "application" object. But how to use it in a Servlet? ...

what happens when we include the same taglib url with same prefix twice?

what happens when i define the same tag lib twice in a jsp. for ex i am having a.jsp and b.jsp inside a.jsp i include b.jsp (@ include not jsp include) and at times i call b.jsp using ajax and i define a taglib <%@ taglib uri="http://www.myorg.com/my/mytaglib" prefix="mytaglib"%> inside a.jsp and b.jsp and use it in a.jsp and b.jsp i...

Difference between Custom Tag and Java Bean?

Difference between Custom Tag and Java Bean? ...

Difference between JSP1.2 and JSP2.0

Difference between JSP1.2 and JSP2.0 ...

Encrypt Sting in JSP... Decrypt in PHP

I have to make a handshake page in php that will take a querystring that is encrypted for a function in Java/JSP and decrypt it in PHP fir use in an application. I have found this to be a good starting point http://propaso.com/blog/?cat=6 but it encrypts in PHP and decrypts in PHP, the reverse of what I need to do. Anyone know common C...

How do I include jsp pages in a Java web app without duplicating code?

Let me just start out by saying I am completely new to Java web apps, so I'm sorry if this is a very basic question. I am writing an app that has the ability for users to login to an account. The top part of each page contains an info bar (kind of like the top bar in GMail) with something like: Logged in as <userid> | Settings | Help ...

For the Web UI gurus

Hi everyone, I finally reached the point in my web app where implementing simple requirements is becoming overwhelming. I'm guessing it's time for a nice refactoring or a simple garbage and redo. Here are the simple requirements I need to implement on a table: 1) make the columns sortable 2) freeze the 2 header rows and first 3 colu...

include a cpp file in jsp

i am very new to jsp... i am currently doing a project where i have to interface a card reader with my html page. i got the card-reader code in a cpp and .h file. is there any way i can use these file with my jsp.. or do i have to recode it in java and include a .js file. specifically, i have a text input for ID on my page. i need it t...

maven, jsp files in dependency

Hi I'm using maven2 for dependency management. I have one project that contains some java files and some jsp files and another project, a web project, that depends on the first project. How do I access the jsp files from the web project? I can see that the jsp files are added to 1-0-SNAPSHOT-sources.jar and not 1-0-SNAPSHOT.jar ( which ...

Display 100000 records on browser / multiple pages.

I would like to display 100000 records on browser / multiple pages with minimal impact on memory. ie Per page 100 records. I would like to move page back and forth. My doubts are 1. Can I maintain all the record inside the memory ? Is this good Idea ? 2) Can I make database connection/query for ever page ? If so how do write a query? ...

Getting the real (virtual) host name under an application server

I have an application running under Jetty, and I want the application to return self referencing absolute URLs (when generating an RSS feed, so a client must be able to work without a "current URL" context). The problem is that I don't know ahead of time under which host name the application will be deployed, and it is quite likely tha...

Is there any way to inject custom controls into JSPs using a servlet?

I am new to JSPs and Servlets - I am wondering if there is any way for a JSP of delegating to a servlet the generation of given areas of the page such as custom controls (AWT stuff and such). The reason why I am looking into this is that JSP pages can get really messy really fast. Examples appreciated! ...

Eliminating Javac warnings for JSPs in Jasper generated Java source files?

When pre-compiling JSPs with the Jasper compiler (using Tomcat), and then the Java compiler I see javac warnings like this (I have javac's -Xlint flag enabled): warning: [unchecked] unchecked call to add(E) as a member of the raw type java.util.List _jspx_dependants.add("/some-jsp.jspf"); Now, it's "just a warning," but I like clean b...

Free JSP hosting

Hi, I am looking for some free JSP hosting, that have support for: 1.Struts 2.JDK 1.6 3.Can have Apache Tomcat 4.one or two MySQL databases 5.Subdomains Thanks for your help BTW. Sorry for my english (I am from Czech) ...

How do I access the root of a WAR?

I need to determine if an image exists in a JSP tag so I can display a default if it doesn't exist. What is the best way to access the War root so that I can check to see if the image exists? Or is there a better solution? ...

One large include file or several smaller ones?

I am writing some jsp and I am wondering if it would be better to have one large include file that I would include with every page or several smaller ones that I would include only on certain pages as needed. Any given page will only need to call a few methods at most ( < 5). If I use one file, it would be 2500+ lines of code. My mai...