-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Writing XLSX from templates don't keep all archive files #4394
Comments
I think this would be difficult to support. Which doesn't mean it can't be done, but it will take a lot of research and time. In the meantime, Excel 365 thinks your file is corrupt:
Do you not see these messages when you open the file? If not, what release of Excel are you using? If so, is it possible to supply a non-corrupt version of the file so that I can research? |
@oleibman Sorry, don't know what I uploaded haha. I edited my post and uploaded the correct version. I thought about extending the Writer/Xlsx.php class, as I saw some logic iterating on the ZipArchive, but that seems to be a lot of work indeed. |
Thank you, the new file looks okay. Just because I don't know anything about it, when I open it, is there anything that differs from how it would appear if there was no custom xml? |
I am loading a template file, editing it and then saving it, like this :
The template file contains some required .xml files in the XLSX archive. When saving it, some of the .xml files are missing, which is problematic for the feature I'm building.
xmlMaps.xml is missing when saving
customXml is missing when saving
You can see by the size of the folders that some files are missing from these too.
Is there a way to do what I want? I just want to add lines to the templates, while keeping all .xml file structure that are necessary. I tried to look into the save() method but it's hard to understand everything that's happening.
templateImportFactureVente_CAF.xlsx
Using 3.3.0
The text was updated successfully, but these errors were encountered: