The word template is saved as a Webpage (*.htm, *.html), to JSP page and add dat

After the word template is saved as a Webpage, HTML format will be converted to the JSP page, add the corresponding dynamic value on the page, adding value contains pictures, this how to treat?? In addition the exported file needs to be copied to the different places (cannot use network).



<%@ page contentType="application/vnd.ms-word; charset=GBK" language="java" import="java.util.*,java.io.*"%>
<%@ taglib uri="tableURI" prefix="Combo" %>
<%response.setContentType("application/msword");%>
<%response.setHeader("Content-Type","application/msword");%>
<%response.setHeader("Content-disposition","attachment;filename=djb.doc");%>
<html xmlns:v="urn:schemas-microsoft-com:vml"
xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:w="urn:schemas-microsoft-com:office:word"
xmlns="http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=Content-Type content="text/html; charset=gb2312">
<meta name=ProgId content=Word.Document>
<meta name=Generator content="Microsoft Word 11">
<meta name=Originator content="Microsoft Word 11">
<link rel=File-List href="xmfiles/filelist.xml">
<link rel=Edit-Time-Data href="xm.files/editdata.mso">

<%
String jc=request.getParameter("jc");
String dbzt=request.getParameter("dbzt");
try{
int j=1;
ArrayList aList = new ArrayList();
ArrayList aListXjdwid = new ArrayList();
aListXjdwid = getNominee.selectXjdw();
%>
<body lang=ZH-CN style='tab-interval:21.0pt;text-justify-trim:punctuation'>

<div class=Section1 style='layout-grid:15.6pt'>

<%
for(int k=0;k<aListXjdwid.size();k++){
%>
<p class=MsoNormal style='margin-left:-.65pt;mso-para-margin-left:-.06gd'><span
lang=EN-US style='mso-bidi-font-size:14.0pt'><o:p>Delegation: <Combo:code displayStyle="" codeColName="xjdwid" descColName="xjdwname" codeTableName="xjdw" condition=" Display=1 order by Xh" code="<%=aListXjdwid.get(k).toString()%>"/></o:p></span></p>





JSP in the code above, does anyone have any good suggestions?? Please guide!!

Started by Addison at December 13, 2016 - 8:02 PM

There is no reply? ?
<%
String photohref = getNominee.getPhoto(sTemp[1]);
if (photohref.equals("")){
photohref="http://"+request.getServerName()+":"+request.getServerPort()+"/XXX/Main/Manager/images/m2.gif";
%>
<p class=MsoNormal align=center style='text-align:center'><span lang=EN-US
style='font-size:12.0pt;Font-family:, mso-bidi-font-family:,;;mso-font-kerning:
0pt'><img width=103 height=138 id="_x0000_i1025"
src="<%=photohref%>" border=0 ></span></p>
<%
}else{
photohref="http://"+request.getServerName()+":"+request.getServerPort()+"/XXX/upload/"+photohref;
%>
<p class=MsoNormal align=center style='text-align:center'><span lang=EN-US
style='font-size:12.0pt;Font-family:, mso-bidi-font-family:,;;mso-font-kerning:
0pt'><img width=103 height=138 id="_x0000_i1025" src="<%=photohref%>" border=0 ></span></p>
<%
}
%>
I am so obtained. Before, now the pictures do not show, and this method if it is not of the net will be the picture does not show.

Posted by Addison at December 18, 2016 - 8:15 PM

Why nobody wants to reply?? It is too simple to disdain to reply?? Hope to have the solution friends to talk about, thank you!

Posted by Addison at December 22, 2016 - 9:11 PM