Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7179767
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T17:12:24+00:00 2026-05-28T17:12:24+00:00

I am using Netbeans 7.1 with Glassfish 3.1.1, and JDK 6. I built a

  • 0

I am using Netbeans 7.1 with Glassfish 3.1.1, and JDK 6. I built a sample project from a Java EE 5 tutorial. Sample Projects Download, The project is the guessNumber project.

I open the project, assign the glassfish server to it, deploy it and run it. The result is this:

File Download Security Warning

What would cause this? Why doesn’t Internet Explorer want to render this as an HTML page and offer to download the file instead? I saved the file. Here it is: guessNumber

I did not change any project settings. I also uninstalled and re-installed Netbeans, Glassfish, and JDK 6 and reinstalled just to be sure nothing got changed in those settings.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T17:12:25+00:00Added an answer on May 28, 2026 at 5:12 pm

    IE does not support HTML files which are served with content type of application/xhtml+xml.

    Change the following line in top of all JSPs

    <%@ page contentType="application/xhtml+xml" %>
    

    to

    <%@ page contentType="text/html" %>
    

    This was a mistake of the tutorial’s authors (or, maybe, a purposeful stab towards IE users that they’re using the wrong browser for the web; it works in real browsers like Chrome, Firefox, etc).


    Unrelated to the concrete problem, don’t use outdated JSF 1.x tutorials/books. Instead use JSF 2.x ones. With JSF 1.x and JSP you’re basically working with dead technology. Glassfish 3.x supports JSF 2.x out the box already. JSF 2.x is part of Java EE 6. Concentrate on finding/reading JSF 2.x tutorials/books.

    See also:

    • What are the main disadvantages of Java Server Faces 2.0?
    • Is it possible to use JSF+Facelets with HTML 4/5?
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a Java EE 5 project developed using Netbeans 6.7.1 with Glassfish v2.1.
I'm following the Java EE firstcup tutorial using Netbeans and Glassfish . When I
im using netbeans for svn. i open a project in netbeans and then i
I am currently writing a java REST Web Service using Netbeans and Glassfish. The
Being new to hibernate, I am using netbeans 7.2, Glassfish 3.x, and mysql. From
I have two Java web services deployed on Glassfish server using Netbeans 7.2.1, both
I have a Java web services deployed on Glassfish server using Netbeans. Service fetches
I am using netbeans glassfish bundle to create a webservice. I am adding operations
I have a jax-ws web service developped using netbeans 7 and glassfish 3.1.2 .
I am using Netbeans 6.8 and Glassfish v3.0. I created an ejb module and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.