HTML to PDF / DOCX / RTF Java converter library › Forums › PD4ML v3 Archived Forums (Read Only) › Troubleshooting › css @media parsing › Re: Re: css @media parsing
Hello All,
I want to include external css files in jsp which is to be transform to pdf.
How do i fix this below issue :
org.w3c.css.sac.CSSException: Encountered ”
12:49:42,111 ERROR [stderr] (default task-60) Was expecting one of:
12:49:42,111 ERROR [stderr] (default task-60) …
12:49:42,111 ERROR [stderr] (default task-60) “{” …
12:49:42,111 ERROR [stderr] (default task-60) “,” …
12:49:42,111 ERROR [stderr] (default task-60)
12:49:42,112 ERROR [stderr] (default task-60) at com.steadystate.css.parser.SACParser.parseStyleSheet(SACParser.java:60)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.html.doc.css.d.Ò00000(Unknown Source)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.html.doc.css.c.super(Unknown Source)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.html.doc.PD4MLHtmlParser.buildDocument(Unknown Source)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.pd4ml.PD4ML.super(Unknown Source)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.pd4ml.PD4ML.render(Unknown Source)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.pd4ml.PD4ML.render(Unknown Source)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.pd4ml.PD4ML.render(Unknown Source)
12:49:42,112 ERROR [stderr] (default task-60) at org.zefer.pd4ml.taglib.PD4MLTransformerTag.render(Unknown Source)
12:49:42,113 ERROR [stderr] (default task-60) at org.zefer.pd4ml.taglib.PD4MLTransformerTag.doEndTag(Unknown Source)
12:49:42,113 ERROR [stderr] (default task-60) at org.apache.jsp.WEB_002dINF.Jsp.itembank.SummaryPDF_jsp._jspService(SummaryPDF_jsp.java:494)
12:49:42,113 ERROR [stderr] (default task-60) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:69)
12:49:42,113 ERROR [stderr] (default task-60) at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
12:49:42,113 ERROR [stderr] (default task-60) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:365)
12:49:42,113 ERROR [stderr] (default task-60) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:321)
12:49:42,113 ERROR [stderr] (default task-60) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:254)
12:49:42,113 ERROR [stderr] (default task-60) at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
12:49:42,114 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:87)
12:49:42,114 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130)
12:49:42,114 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176)
12:49:42,114 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
12:49:42,114 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)
12:49:42,114 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:394)
12:49:42,114 ERROR [stderr] (default task-60) at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:56)
12:49:42,114 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
12:49:42,115 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:85)
12:49:42,115 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:57)
12:49:42,115 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
12:49:42,115 ERROR [stderr] (default task-60) at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)
12:49:42,115 ERROR [stderr] (default task-60) at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)
12:49:42,115 ERROR [stderr] (default task-60) at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)
12:49:42,115 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:207)
12:49:42,116 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletInitialHandler.dispatchToPath(ServletInitialHandler.java:150)
12:49:42,116 ERROR [stderr] (default task-60) at io.undertow.servlet.spec.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:157)
12:49:42,116 ERROR [stderr] (default task-60) at org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:238)
12:49:42,116 ERROR [stderr] (default task-60) at org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:263)
12:49:42,116 ERROR [stderr] (default task-60) at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1208)
12:49:42,116 ERROR [stderr] (default task-60) at org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:992)
12:49:42,116 ERROR [stderr] (default task-60) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:939)
12:49:42,117 ERROR [stderr] (default task-60) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
12:49:42,117 ERROR [stderr] (default task-60) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936)
12:49:42,117 ERROR [stderr] (default task-60) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:827)
12:49:42,117 ERROR [stderr] (default task-60) at javax.servlet.http.HttpServlet.service(HttpServlet.java:687)
12:49:42,117 ERROR [stderr] (default task-60) at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
12:49:42,117 ERROR [stderr] (default task-60) at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
12:49:42,117 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:87)
12:49:42,117 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130)
12:49:42,118 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176)
12:49:42,118 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
12:49:42,118 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)
12:49:42,118 ERROR [stderr] (default task-60) at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:394)
12:49:42,118 ERROR [stderr] (default task-60) at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:56)
12:49:42,118 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
12:49:42,119 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:85)
12:49:42,119 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:59)
12:49:42,119 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
12:49:42,119 ERROR [stderr] (default task-60) at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:81)
12:49:42,119 ERROR [stderr] (default task-60) at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)
12:49:42,119 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:113)
12:49:42,119 ERROR [stderr] (default task-60) at io.undertow.security.handlers.AuthenticationCallHandler.handleRequest(AuthenticationCallHandler.java:52)
12:49:42,119 ERROR [stderr] (default task-60) at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:45)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:65)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.security.handlers.SecurityInitialHandler.handleRequest(SecurityInitialHandler.java:70)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:218)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:205)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:69)
12:49:42,120 ERROR [stderr] (default task-60) at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:134)
12:49:42,121 ERROR [stderr] (default task-60) at io.undertow.server.HttpHandlers.executeRootHandler(HttpHandlers.java:36)
12:49:42,121 ERROR [stderr] (default task-60) at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:619)
12:49:42,121 ERROR [stderr] (default task-60) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
12:49:42,121 ERROR [stderr] (default task-60) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
12:49:42,121 ERROR [stderr] (default task-60) at java.lang.Thread.run(Thread.java:744)
12:49:42,747 INFO [stdout] (default task-60) done in 1648ms.
my Jsp contains:
<%@page
import="com.schoolcity.stars.controller.itembank.ItemBankController"%>
<%@ page import="java.util.Map"%><%@ page import="java.util.List"%><%@ page
import="java.util.ArrayList"%><%@ page import="java.util.HashMap"%><%@ page
import="com.schoolcity.stars.dto.itembank.ItemSummary"%><%@ page
import="com.schoolcity.stars.entity.assessment.Assessment"%><%@ page
import="com.schoolcity.stars.entity.assessment.AssessmentForm"%><%@ page
import="com.schoolcity.stars.entity.common.InstanceSubject"%><%@ page
import="com.schoolcity.stars.entity.itembank.ItemChoice"%><%@ page
import="com.schoolcity.stars.entity.itembank.Item"%>
<%
Map
Map
List
List
Assessment objAssessmentData = (Assessment) request.getAttribute(“ASSESSMENT_DATA”);
Map
String strContextPath = request.getContextPath();
System.out.println(“>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>” + strContextPath);
System.out.println(“I m in summary PDF”);
%>
<%@ taglib uri="/WEB-INF/tlds/pd4ml.tld" prefix="pd4ml"%><%@ page contentType="text/html; charset=ISO8859_1"%>
pd4ml.enableDebugInfo();
Assessment Name:
Year:
Subject:
Item # | Standard | Item ID | Correct Answer | Points | Passage Name | Difficulty Level | DOK |
---|---|---|---|---|---|---|---|
<%=index++%> | <%=mpeItemSummary.getValue().getFullNumber()%> | <%=mpeItemSummary.getValue().getPublisherExtId()%> | <%=mpeItemSummary.getValue().getCorrectAnswer()%> | <%=mpeItemSummary.getValue().getPoints()%> | <%=mpeItemSummary.getValue().getPassageTitle()%> | <%=mpeItemSummary.getValue().getDifficultyCode()%> | <%=mpeItemSummary.getValue().getDepthOfKnowledgeCode()%> |
STANDARD | DIFFICULTY LEVEL | BLOOM’S TAXONOMY | Total | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
<%=strDC%> | <%=strBC%> | |||||||||||
<%=mpeItemSummary.getValue().getFullNumber()%> | 1 | N/A | <%=mpeItemSummary.getValue().getBloomsCode()%> | |||||||||
Total: | <%=iDLC%> | <%=iDMC%> | <%=iDHC%> | <%=iDNC%> | <%=iBCr%> | <%=iBEv%> | <%=iBAn%> | <%=iBAp%> | <%=iBUn%> | <%=iBRe%> | <%=iBNa%> |
<% for(Map.Entry
%>
Question #<%=count++%> (<%=mpeItems.getValue().getName()%>) | ||
---|---|---|
<%=mpeItems.getValue().getStem()%>
|
<%=sbfullname.toString()%> <% } and i am using bellow jars: pd4ml_demo.jar , pd4ml_tl_demo.jar , ss_css2.jar and w3c.jar files in lib of web-inf folder and have included the respective tlds. |