netbeansでWebプロジェクトを作成しましたが、time.jspページはInternet Explorerでページを開く代わりにダウンロードファイルのように開いています。 どうしてですか?おかげさまで ダウンロードファイルのようにJSPファイルを開く
<jsp version="2.1" xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:jsp="http://java.sun.com/JSP/page"
xmlns:webuijsf="http://www.sun.com/webui/webuijsf">
<jsp:directive.page contentType="text/html:charset=UTF-8" pageEncoding="UTF-8"/>
<f:view>
<webuijsf:page id="page1">
<webuijsf:html id="html1">
<webuijsf:head id="head1" title="Web Time: A Simple Example">
<webuijsf:link id="link1" url="/resources/stylesheet.css"/>
<webuijsf:meta content="60" httpEquiv="refresh"/>
</webuijsf:head>
<webuijsf:body id="body1" style="-rave-layout: grid">
<webuijsf:form id="form1">
<webuijsf:staticText id="timeHeader"
style="font-size: 18px; left: 24px; top: 24px;
position: absolute"
text="Current time on the web server"/>
<webuijsf:staticText binding=""
id="clockText" style="background-color: black;
color: yellow; font-size: 18px; left: 24px;
top: 48px; position: absolute"/>
</webuijsf:form>
</webuijsf:body>
</webuijsf:html>
</webuijsf:page>
</f:view>
問題を理解するのに役立つかもしれないコードを教えてください。 –
は自分のコードを追加しました!ありがとうございました –
レスポンスヘッダーでコンテンツタイプを確認しましたか?それは何を言う –