problem with jsp page
Posted: Wed Nov 10, 2004 4:35 pm
http://209.82.100.37:8080/voicestockagent/lesson5.jsp
when I try to validate this I get an error
VoiceXML Validator:
File: http://209.82.100.37:8080/voicestockagent/lesson5.jsp
Validation Results:
Fatal Error at line 1, char 7
Message: The XML or Text declaration must start at line/column 1/1
scanFirst() failed
I have tried this page on several sites and I know it works.
The full file is included below:
<%@ page language="java" %>
<?xml version="1.0"?>
<vxml version="2.0">
<meta name="maintainer" content="bmatichuk@celcorp.com"/>
<property name="LOGLEVEL" value="2"/>
<form id="actions">
<field name="choice">
<prompt>
Please choose from the following:
To buy stocks, please say buy.
To sell stocks, please say sell.
To check pending transactions, please say pending.
To check holding stocks, please say holding.
To check transaction history, please say history.
To find a stock quote, please say quote.
To check your status, please say status.
</prompt>
<grammar>
buy | sell | pending | holding | history | quote | status
</grammar>
<noinput>
I didn't hear you.
<reprompt/>
</noinput>
<nomatch>
I didn't quite understand you.
<reprompt/>
</nomatch>
<filled>
<if cond="choice=='buy'">
OK let's buy stock.
<elseif cond="choice=='sell'"/>
OK let's sell stock.
<elseif cond="choice=='pending'"/>
OK let's check your pending transactions.
<elseif cond="choice=='holding'"/>
OK let's check your holdings.
<elseif cond="choice=='history'"/>
OK let's check your transaction history.
<elseif cond="choice=='quote'"/>
OK let's find a stock quote.
<goto next="#quote"/>
<elseif cond="choice=='status'"/>
OK let's check your status.
</if>
</filled>
</field>
</form>
<form id = "quote">
<field name = "symbol">
<prompt>
Please spell the stock's symbol, letter by letter.
</prompt>
<grammar src="http://209.82.100.37:8080/voicestockage ... osr3.grxml"/>
<noinput>
I didn't hear you.
<reprompt/>
</noinput>
<nomatch>
I didn't quite understand you.
<reprompt/>
</nomatch>
<filled>
You want to know the quote for <value expr="symbol"/>.
<submit next="http://209.82.100.37:8080/voicestockage ... ucceed.jsp" namelist ="symbol"/>
</filled>
</field>
</form>
</vxml>
when I try to validate this I get an error
VoiceXML Validator:
File: http://209.82.100.37:8080/voicestockagent/lesson5.jsp
Validation Results:
Fatal Error at line 1, char 7
Message: The XML or Text declaration must start at line/column 1/1
scanFirst() failed
I have tried this page on several sites and I know it works.
The full file is included below:
<%@ page language="java" %>
<?xml version="1.0"?>
<vxml version="2.0">
<meta name="maintainer" content="bmatichuk@celcorp.com"/>
<property name="LOGLEVEL" value="2"/>
<form id="actions">
<field name="choice">
<prompt>
Please choose from the following:
To buy stocks, please say buy.
To sell stocks, please say sell.
To check pending transactions, please say pending.
To check holding stocks, please say holding.
To check transaction history, please say history.
To find a stock quote, please say quote.
To check your status, please say status.
</prompt>
<grammar>
buy | sell | pending | holding | history | quote | status
</grammar>
<noinput>
I didn't hear you.
<reprompt/>
</noinput>
<nomatch>
I didn't quite understand you.
<reprompt/>
</nomatch>
<filled>
<if cond="choice=='buy'">
OK let's buy stock.
<elseif cond="choice=='sell'"/>
OK let's sell stock.
<elseif cond="choice=='pending'"/>
OK let's check your pending transactions.
<elseif cond="choice=='holding'"/>
OK let's check your holdings.
<elseif cond="choice=='history'"/>
OK let's check your transaction history.
<elseif cond="choice=='quote'"/>
OK let's find a stock quote.
<goto next="#quote"/>
<elseif cond="choice=='status'"/>
OK let's check your status.
</if>
</filled>
</field>
</form>
<form id = "quote">
<field name = "symbol">
<prompt>
Please spell the stock's symbol, letter by letter.
</prompt>
<grammar src="http://209.82.100.37:8080/voicestockage ... osr3.grxml"/>
<noinput>
I didn't hear you.
<reprompt/>
</noinput>
<nomatch>
I didn't quite understand you.
<reprompt/>
</nomatch>
<filled>
You want to know the quote for <value expr="symbol"/>.
<submit next="http://209.82.100.37:8080/voicestockage ... ucceed.jsp" namelist ="symbol"/>
</filled>
</field>
</form>
</vxml>