Cannot open xml file

519 views Asked by At

I'm using phpword library to print data from database by using template. I realized that phpword does not replace any of the keywords with my input so I searched what causing it and found that word generates arbitrary tags around my keywords so phpword fails to find my keys.

Then I changed my template's format from .docx to zip to open document.xml file to erase unnecessary tags around my keyword but I cannot open document.xml, it says there is an error in row 2 but whole XML file is in row 2 so it is impossible to find where is the error.

Some suggested that use notepad++ and xmlplugin to regenerate XML file with proper line breaks. I did it but error still shows the same row and I can't find the error, also I used online tools to check whether there is an error or not in my document.xml but those tools says your XML file is fine, sorry for the long explanation, thanks in advance.

0

There are 0 answers