# Pro Reports PDF export is corrupt somehow

**URL:** <https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080>\
**Category:** Bug\
**Tags:** pro-reports\
**Created:** [July 8, 2024, 9:34pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080 "2024-07-08T21:34:53Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![zackw](https://community.mainwp.com/user_avatar/community.mainwp.com/zackw/32/1504_2.png) [@zackw](https://community.mainwp.com/u/zackw)\
**Post date:** [July 8, 2024, 9:34pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080/1 "2024-07-08T21:34:53Z")

</div>

Note that this has worked fine for years and seems to be a recent problem. I don’t know what version it started happening though. I first noticed in early May or probably in April.

When I export _any_ PDF template for a site (I have 7of them), the PDF will open on my Windows computer with my preferred PDF app “PDF-XChange Editor Plus” (a commercial paid app), but the app shows this message when the PDF opens:

![pdf issue](https://community.mainwp.com/uploads/default/original/2X/e/eb238b88a1d27ebb4ff2ac958ee4f19da7111f85.png)

When I click the “Show Problem Details” button, it says this:

 ![pdf issue 2](https://community.mainwp.com/uploads/default/original/2X/c/cadf4453861c14895fae42df35a239a14da393bb.png)

When I change any details in the PDF so that it saves the changes, the error goes away or was fixed I guess.

Like I mentioned, this has never happened before and is a new thing. I don’t know what this error means but my first stop is to see if it could be something in the MainWP Pro Reports export itself.  
It’s not in PDF-XChange since every other PDF I use or download or get in daily operations doesn’t show this message, it only comes from PDFs in Pro Reports.

I have tested using the default “modern” template so it’s not based on any customizations either.

I have used an online tool like this one: [Repair PDF files online. Free tool to repair PDF](https://www.ilovepdf.com/repair-pdf)  
It repairs the file and this new repaired file opens without the errors.

I created a test template that only outputs a single line of text, no images or other fancy stuff, and even this is corrupt too. Here is a copy of that PDF zipped up:

> **[Dropbox](https://www.dropbox.com/scl/fi/k60ezi9lpvr6123qgvni6/Pro-Reports-Generated-Corrupt-PDF-Test.zip?rlkey=ngadeybw6ql0xsnqux06eb89d&dl=0)**

Hopefully this is something that can be investigated and maybe there is a change to the PDF generator that can fix it. It’s becoming really annoying after months of dealing with it so I wanted to report it!

Other PDF readers will simply ignore problems like this. Chrome or Firefox will open it without an error message. I can do that too in PDF-XChange, by turning off their warnings about corrupt PDFs, but I’d rather not do that. I would rather the PDF generation be exported properly if possible, from the start.

Thanks!

---

<div class="post-metadata">

**Author:** ![bojan](https://community.mainwp.com/user_avatar/community.mainwp.com/bojan/32/3059_2.png) [@bojan](https://community.mainwp.com/u/bojan)\
**Post date:** [July 9, 2024, 12:18pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080/2 "2024-07-09T12:18:53Z")

</div>

Hey @zackw

Is the PDF corrupted in this way only when you download it, or also when it gets sent out as an attachment of the report?

Also, are you by any chance hosting the MainWP Dashboard on Siteground and using their Ultrafast PHP?  
Or if not on Siteground, maybe on some other host that is using their own customized PHP offering?

Can you please post the community system report from your MainWP Dashboard for review? The report is located in your Dashboard under Info → Server, on the top right of the page.

Be sure to use the button like the one below; this button hides all your private information:

![image](https://community.mainwp.com/uploads/default/original/1X/ed5dbe4a960a253f65accc51abff1ed379a4ef8e.png)

Pressing the button auto-copies the report to your clipboard then just paste it in a reply here.

---

<div class="post-metadata">

**Author:** ![zackw](https://community.mainwp.com/user_avatar/community.mainwp.com/zackw/32/1504_2.png) [@zackw](https://community.mainwp.com/u/zackw)\
**Post date:** [July 9, 2024, 9:12pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080/3 "2024-07-09T21:12:20Z")

</div>

Interesting, I used the email instead of download and when I download it out of the email, the error didn’t happen.

The server is a VULTR VPS running CyberPanel.

Report:

```auto
### WordPress Check Required Detected Status ###

FileSystem Method = direct direct Pass        
MultiSite Disabled =true true Pass        
WordPress Memory Limit >=64M 128M Pass        
WordPress Version >=6.2 6.5.5 Pass        

### PHP Required Detected Status ###

cURL Extension Enabled =true true Pass        
cURL Timeout >=300 seconds 300 Pass        
cURL Version >=7.18.1 7.68.0 Pass        
OpenSSL Version >=OpenSSL/1.1.0 OpenSSL/1.1.1f Pass        
OpenSSL Working Status Yes Yes Pass        
PCRE Backtracking Limit >=10000 1000000 Pass        
PHP Allow URL fopen N/A YES                                                      
PHP Disabled Functions N/A , pcntl_alarm, pcntl_async_signals, pcntl_exec, pcntl_fork, pcntl_get_last_error, pcntl_getpriority, pcntl_setpriority, pcntl_signal, pcntl_signal_dispatch, pcntl_signal_get_handler, pcntl_sigprocmask, pcntl_sigtimedwait, pcntl_sigwaitinfo, pcntl_strerror, pcntl_unshare, pcntl_wait, pcntl_waitpid, pcntl_wexitstatus, pcntl_wifcontinued, pcntl_wifexited, pcntl_wifsignaled, pcntl_wifstopped, pcntl_wstopsig, pcntl_wtermsig,            
PHP Exif Support N/A YES                                                      
PHP IPTC Support N/A YES                                                      
PHP Loaded Extensions N/A Core, PDO, Phar, Reflection, SPL, SimpleXML, Zend OPcache, bcmath, bz2, calendar, ctype, curl, date, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, intl, json, ldap, libxml, litespeed, mbstring, memcached, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, pdo_mysql, pdo_sqlite, posix, pspell, readline, redis, session, soap, sockets, sodium, sqlite3, standard, sysvmsg, sysvsem, sysvshm, tidy, timezonedb, tokenizer, xml, xmlreader, xmlrpc, xmlwriter, xsl, zip, zlib            
PHP Max Execution Time >=30 seconds 60 Pass        
PHP Max Input Time >=30 seconds 120 Pass        
PHP Memory Limit >=256M 256M Pass        
PHP Post Max Size >=2M 30M Pass        
PHP Safe Mode Disabled =true true Pass        
PHP Upload Max Filesize >=2M 20M Pass        
PHP Version >=7.4 7.4.33 Pass        
PHP XML Support N/A YES                                                      
SSL Extension Enabled =true true Pass        
SSL Warnings = empty Pass        

### MySQL Required Detected Status ###

MySQL Client Encoding N/A utf8                                                     
MySQL Mode N/A ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION            
MySQL Version >=5.0 10.3.38-MariaDB-0ubuntu0.20.04.1 Pass        

### Server Configuration Detected Value ###

Accept Content text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7
Accept-Charset Content N/A                                                    
Architecture 64 bit                                         
Gateway Interface                                                                         
HTTPS ON                                                     
Memory Usage 8.45 MB                                                
Operating System Linux                                                  
Request Time 1720559425                                             
Server Protocol HTTP/1.1                                               
Server self connect Not expected HTTP response body:                       
Server Software LiteSpeed                                              
User Agent Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36

### MainWP Dashboard Settings Detected Value ###

Abandoned plugins/themes tolerance 550                                                    
Basic uptime monitoring enabled No                                                     
MainWP Dashboard Version Latest: 5.1.1 | Detected: 5.1.1 Pass                   
MainWP legacy backups enabled No                                                     
Maximum number of pages to return                                                         
Maximum number of posts to return                                                         
Maximum simultaneous install and update requests3                                                      
Maximum simultaneous requests 4                                                      
Maximum simultaneous requests per ip1                                                      
Maximum simultaneous sync requests 8                                                      
Minimum delay between requests 200                                                    
Minimum delay between requests to the same ip1000                                                   
Number of connected sites 47                                                     
Optimize data loading Yes                                                    
Plugin advanced automatic updates enabledYes                                                    
Primary Backup System MainWP UpdraftPlus Extension                           
REST API enabled No                                                     
Site health monitoring enabled No                                                     
Theme advanced automatic updates enabledYes                                                    
Use WP Cron Yes                                                    
WP Core advanced automatic updates enabledNo                                                     

### Extensions Version License Status ###

Advanced Uptime Monitor Extension 5.3.1 Active Pass        
MainWP Cache Control Extension 5.0 Active Pass        
MainWP Custom Dashboard Extension 5.0.1 Active Pass        
MainWP Domain Monitor Extension 5.0.2 Active Pass        
MainWP iThemes Security Extension 5.0.1 Active Pass        
MainWP Pro Reports Extension 5.0.4 Active Pass        
MainWP SSL Monitor Extension 5.0.1 Active Pass        
MainWP Sucuri Extension 5.0 Active Pass        
MainWP UpdraftPlus Extension 5.0.1 Active Pass        

### Plugin Version Status ###

FluentSMTP 2.2.80 Active                                       
Loginizer 1.8.8 Active                                       
MainWP Dashboard 5.1.1 Active                                       
UpdraftPlus - Backup/Restore 2.24.4.26 Active                                       
WPCodeBox 1.4.1 Active                                       

```

How is the emailed report different from the downloaded one? Is it not the same generator tool running?

---

<div class="post-metadata">

**Author:** ![bojan](https://community.mainwp.com/user_avatar/community.mainwp.com/bojan/32/3059_2.png) [@bojan](https://community.mainwp.com/u/bojan)\
**Post date:** [July 10, 2024, 12:15pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080/4 "2024-07-10T12:15:29Z")

</div>

Thanks for the update.

> [@zackw](#):
>
> How is the emailed report different from the downloaded one? Is it not the same generator tool running?

The same library, Dompdf, generates the PDF, so it’s rather odd that the issue is present only when the report is downloaded.

Would you mind opening a private [Help Desk ticket](https://mainwp.com/my-account/get-support/) so the development team can take a closer look?

And please refer to this Managers thread by its URL in the ticket.

---

<div class="post-metadata">

**Author:** ![zackw](https://community.mainwp.com/user_avatar/community.mainwp.com/zackw/32/1504_2.png) [@zackw](https://community.mainwp.com/u/zackw)\
**Post date:** [July 11, 2024, 10:58pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080/5 "2024-07-11T22:58:54Z")

</div>

Created a ticket, thanks!

---

<div class="post-metadata">

**Author:** ![bojan](https://community.mainwp.com/user_avatar/community.mainwp.com/bojan/32/3059_2.png) [@bojan](https://community.mainwp.com/u/bojan)\
**Post date:** [July 25, 2024, 7:01pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080/6 "2024-07-25T19:01:51Z")

</div>

We’ve determined that this issue manifests itself only in the PDF-Xchange Editor, and not in any other readers we’ve tried, such as Adobe Reader, Sumatra, and numerous web browsers.  
However, we don’t think the issue is being caused by the PDF-Xchange Editor.

This is also a low-impact issue since the PDF file can be read properly even in PDF-Xchange with only a notice bar at the top of the reader.

We will thus leave this issue as is, considering the PDF is generated by the DOMPDF library, which we believe does a good job of generating standard-compliant PDF files.

---

<div class="post-metadata">

**Author:** ![system](https://community.mainwp.com/uploads/default/original/2X/4/4cfc87ac67e4ebdbfa0bbf0b19c8657f35a29a5b.png) [@system](https://community.mainwp.com/u/system)\
**Post date:** [July 26, 2024, 7:01pm UTC](https://community.mainwp.com/t/pro-reports-pdf-export-is-corrupt-somehow/9080/7 "2024-07-26T19:01:56Z")

</div>

Closed on July 26, 2024, 7:01pm UTC

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
