Serving an HTML page WITH images using GETRESOURSEASSTREAM()

Hello I am having problems displaying a webpage using getresourseasstream.

I know how to serve images, and other types of files, but what I really want to do is serve an entire webpage, complete with images when a user is logged on.

The images are under my WEB-INF folder so only authenticated users may access the images within the webpage, ONLY if it is served to them (my guess is using getresourceasstream as well).  So is there any way to do this?

Or is there some other approach, where I create a context and somehow attribute the image and html to each other?

Simply restated, I want to serve my protected webpage (complete with images), which are both stored under WEB-INF.

I have only seen solutions where single files are streamed, none with webpages with images.

Thanks.

mrmathewAsked:
Who is Participating?
 
CetusMODCommented:
PAQed with points refunded (50)

CetusMOD
Community Support Moderator
0
 
actonwangCommented:
put file or images you require login inside <security-constraint>.
0
 
mrmathewAuthor Commented:
I am using LDAP for authentication so cannot use constraints (too many users)..

I actually solved my problem, by simply serving the images via another JSP page..

thanks,.
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.