PDF-Template is Empty

Okay thanks for that. And sorry for not sending the information in a single post. However, what do I do to solve this issue besides upgrading? Because if it was working before what cause the bug. Additionally if I upgrade do I lose data in the database

Correction to my previous advice: you can’t upgrade directly to PHP 7.3, since it is only compatible starting from SuiteCRM 7.11.5, so you’ll have to get to that first, or just use PHP 7.2 for simplicity).

Upgrading PHP and/or SuiteCRM will not change your database. When upgrades go well, everything is the same in the end. But upgrading always requires some care and it’s better to have full back-ups (files + database) to make sure you can always backtrack if needed.

Having an unsupported PHP version can easily be the cause of the bug - so that is always the first thing to try before any other troubleshooting. I understand that the fact that “it was working fine just now” points to something else, but you never now - any change in your use of the app, or in your template, can lead the execution into a different part of the code, and trigger a bit of unsupported code…

I didn’t look closely at your template, but if you created the problem by changing something in it, you can always change it back, or simply remove all of it (from the database) until the UI screens are back to a functional state, and then try changing the template bit by bit until you find the exact expression that triggers the problem.

I did try that but I’m still getting the error! It would be something on the page but I don’t how to restore that. The view page works fine, it’s just the edit and create page that’s causing the issue.

Have you tried several options from Admin / Repair?

The QR & R

plus anything Javascript-related

I did do a repair; nothing happened.

I’m no longer receiving the error message, after disable ajax and re-enable; however, the create page is completely blank now.

Time to check your logs again, you probably have a FATAL now

But I’m not seeing any fatal error in the logs

You’re not just looking for FATAL errors, you’re troubleshooting your problem.Try to think like a detective :male_detective:

Make a note of the exact time that you’re getting a white screen, and check the timestamps on both your logs at that time, to see if there are any clues there.

If there are, go Google for that message and see if you can find solutions or workarounds.

But can you think of anything that would cause it?

I’m an engineer. Why would I want to guess when I’m far from exhausting the troubleshooting steps available to me?

Examining logs, trying variations to the problem, debugging code step by step. That’s how to get answers.

But I can’t do these things on other people’s systems, from a distance. So I guess if you’re not skilled enough to do it, you need to go get some help from people who can visit your system and troubleshoot.

Good luck!

PHP Fatal error: Uncaught Error: Class name must be a valid object or a string in C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\modules\AOS_PDF_Templates\views\view.edit.php:105
But I’m not seeing what’s wrong with the line.

It seems there is a module name in your template that doesn’t correspond to an actual module. It might be just a tiny difference (like account instead of accounts or something like that)

Maybe you can add some logging just before that line, printing the $relate_module_name variable.

UserUserUserAccountCampaignUserUserUserAccountContact that’s what I got

The template is not showing, so how would I make the changes.

With phpMyAdmin, through the database.

Is it the database table names I’m changing or what exactly?

No, I meant the template content (the description field).

but meanwhile I saw the stack trace that you included in the post you later deleted, and it seems to be crashing in the setfields function, which runs before interpreting the template contents.

I wonder what could make that fail. Did you happen to change pdf_template_type_dom in Admin / Dropdown Editor? Do you see any weird values there?

Can you please post the entire error+stack trace of the two different errors you’re getting? One in line 32, one in line 105

I have this bit:

Stack trace:
#0 C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\modules\AOS_PDF_Templates\views\view.edit.php(32): AOS_PDF_TemplatesViewEdit->setFields()
#1 C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\include\MVC\View\SugarView.php(226): AOS_PDF_TemplatesViewEdit->display()
#2 C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\include\MVC\Controller\SugarController.php(435): SugarView->process()
#3 C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\include\MVC\Controller\SugarController.php(375): SugarController->processView()
#4 C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\include\MVC\SugarApplication.php(113): SugarController->execute()
#5 C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\index.php(52): SugarApplication->execute()
#6 {main}
thrown in C:\Bitnami\suitecrm-7.11.2-0\apps\suitecrm\htdocs\modules\AOS_PDF_Templates\views\view.edit.php on line 105
This is the error mesage

The structure is: first the error, then the stack trace (lines starting with those # numbers). So you should give me something like this:

Error in line 32
#0 stack item
#1 stack item
#2 stack item
...
Error in line 105
#0 stack item
#1 stack item
#2 stack item
...

If in doubt, just copy-paste a bunch of extra stuff and I’ll find what I need :slight_smile:

I make a change to the pdf_template_type_dom and remove the one that I created, it was a custom module that I had added. But the fields remain and they are fine.