PHP Classes

Header formating error

Recommend this page to a friend!

      PHP Word DOCX to HTML with Images  >  All threads  >  Header formating error  >  (Un) Subscribe thread alerts  
Subject:Header formating error
Summary:I have found and fixed small formatting error.
Messages:2
Author:Maksym Chocieszy?ski
Date:2022-09-05 18:44:34
 

  1. Header formating error   Reply   Report abuse  
Picture of Maksym Chocieszy?ski Maksym Chocieszy?ski - 2022-09-05 18:44:34
I think there is an error in readDocument($filename). Header formatting is not cleared in the while loop. After it is set once, i will be set in all next paragraphs too.

I've added $formatting['header'] = 0; on line 452, before preg_match and it fixed it for me.

Also it is language dependent. In polish it is Nagwek1 instead of Heading1 and so on.

  2. Re: Header formating error   Reply   Report abuse  
Picture of supportad4 supportad4 - 2024-03-23 11:31:00 - In reply to message 1 from Maksym Chocieszy?ski
You saved my life dear friend! Thanks for the correction. This class was working fine, but that repeated heading error was rendering it useless. You fixed it! Many thanks!