Here it is:
Apologies, it’s a long post and I did speed read. it.
Is there anything in the .htaccess file that might be forcing a PHP version?
I checked that because I saw another post and it seems right.
The last part is:
# Set the “ea-php81” package as the default “PHP” programming language. <IfModule mime_module> AddHandler application/x-httpd-ea-php81 .php .php8 .phtml </IfModule>
Yes, it was the first thing we checked. Puzzling isn’t?
I’m asking the techs to recheck the latest upgrade of CLI to be certain that part is done and well.
Is this server specifically just for invoiceninja or do you have other sites on the same server?,
That’s opcode caching for cli. Shouldn’t be related to any issues.
The error that showed yesterday was from another thing (cronjob), not the app persé.
So, I upgraded to v5.6.31-C123 but it stills not loading the client portal pdf preview. No errors are showing on the logs. Actually, haven’t shown errors for few days. The PDF loads while creating the invoice, just not on the popup and when you use the link that appears on the window and open it, it then will show the amount of the invoice and shows as “viewed” in the app. If you click “Pay Now” without going directly to the link shown, it will display like $0 (like is not being generated).
Also, I saw some “commits” on GitHub that I don’t see on the version, and they have to do with the pdf and invoice creation, but I might be wrong because even the line numbers don’t match.
Do you see the same errors in the browser console in the client portal?
You could try overwriting with the full package including composer dependencies.
I really need a response. I could reinstall everything again and bring the database but what if I go through all that trouble and solve NOTHING, then what am I supposed to do?
Trying either a clean install or copying the latest release over the current install I think is the best next step.
Now I know that it has to do with IN being installed in a sub-directory. The livewire is not finding that file since it’s looking as if my website was on root. I’ve tried several “fixes” from here and from the Internet, they didn’t solve the problem. I will try to overwrite all the files, I hope that doesn’t make it worse. I already scanned to see if there were different files and they aren’t. There’s only 1 file that I have on my backups that is new (besides of course of env). The files is: \invoice-ninja\public\js\clients\invoices\payment.js
I also compare the files env, config\livewire.php and other related to a new installation I have on same server and besides the domain, they are identical.
Maybe the suggestion here will help:
I tried that one but I will try again.
After many many many tests, I KNOW for a fact the issue here is the asset_url. The problem is that after following many different fixes that I’ve found here and all over the Internet, I fix something but something else brakes.
Here are my fixes and the issues:
Fix #1: adding the asset_url on the env file, doesn’t fix anything. The livewire.js continues going to the main dir to look for the file.
Fix #2: adding env(‘ASSET_URL’), to the livewire config file, solves that issue, but brings another issue Internal Server Error with a strict-origin-when-cross-origin. The same result when adding only env(‘APP_URL’), or adding both. I saw another adding env(‘ASSET_URL’, null), which brakes completely the admin and the preview.
Fix #3: adding the full domain to the vendor file as explained here:
Client Portal page changes or sorting - #6 by extremeskillz
…that also failed.
FYI: I did 2 new installations, one on the root of another account, and another one on a sub-dir. The one on root worked beautifully when previewing the invoice, the one on sub-dir did the same thing, same error. The one of the error was put on root and changed the env lines accordingly… It worked fine.
It does sound like a bug, but as a workaround, you could install on a subdomain.