0

I'm using VXML in JSP page. Sample code below:

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE vxml PUBLIC "-//W3C//DTD VOICEXML 2.0//EN" "http://www.w3.org/TR/voicexml20/vxml.dtd" >

<%@page import="VXMLPropertiesLoader"%>
<%@page import="Context"%>

<%
    Context context = new Context(this.getServletContext());
    VXMLPropertiesLoader vxmlPropertiesLoader = (VXMLPropertiesLoader) context.getBean("vxmlPropertiesLoader");
%>

<vxml version="2.0"
xmlns="http://www.w3.org/2001/vxml" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://www.w3.org/2001/vxml http://www.w3.org/TR/voicexml20/vxml.xsd" application="root.jsp">

<form>
    <block>
        <prompt>
            <break time="<%= vxmlPropertiesLoader.getVXMLProperty("welcome_delay") %>"/>        
            <audio expr="'/Service/<%= vxmlPropertiesLoader.getVXMLProperty("waiting_music") %>'+audioExt">
            </audio>
        </prompt>
    </block>
</form>

  1. The var break_time is correctly set, as well as audio_expr
  2. The imported_pages are in the WEB-INF/classes

Eerything is fine except the server states : CRITICAL Err=205|VXIinterpreterRun: Failed to parse the URI's content. Make sure that this document consists of valid VXML.

In W3C validator it states that the <%@ is illegal ...

  • 1
    Page directive(s) at the top: `<%@page contentType="text/xml; charset=ISO-8859-1"%>`. Then access the XML in the browser and inspect the source. `<%@` should not be in the XML source. – Joop Eggen Aug 14 '14 at 13:26
  • There is no closing vxml tag. Does adding that help? – Jerry Jeremiah Aug 15 '14 at 08:16
  • 1
    Found the error. Was missing the simple quote (even if in my post they were) '/Service/<%= vxmlPropertiesLoader.getVXMLProperty("waiting_music") %>' EcMaScript couldn't evaluate: var = "123" -> ERROR ............BUT ........... var = "'123'" -> OK Thanks for help – Antoine Saverimoutou Aug 18 '14 at 12:32

0 Answers0