<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[FrontAccounting forum — PHP 8]]></title>
	<link rel="self" href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=9899&amp;type=atom" />
	<updated>2023-07-19T09:58:08Z</updated>
	<generator>PunBB</generator>
	<id>https://frontaccounting.com/punbb/viewtopic.php?id=9899</id>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=42434#p42434" />
			<content type="html"><![CDATA[<p>Once I change the coding on the Rep17, it sends the pdf as an attachment. When emailing an invoice or any document, it creates this code inside the email. Cannot send that to the clients.</p><p>It is the emailing function in FA that creates the issue. </p><p>Relating to the following post:</p><br /><br /><p>I found a solution for the reporting/includes/class.mail.inc</p><p>I have found the solutions by changing all the \n code in the file to \r\n and it works on both PHP7.4 and PHP8.0</p><p>Emails are now sending and displaying correctly when sent from FA.</p><p>\r\n is for a new line in windows as for \n in the new line in Linux.</p><p>Use \r\n instead of \n for your implode -- explicitly specifies CRLF as the line terminator.</p><p>When I change this in the lass.mail.inc it send correctly on PHP8</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2023-07-19T09:58:08Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=42434#p42434</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=42404#p42404" />
			<content type="html"><![CDATA[<p>The base64 dedoded string of the above is a PDF file that comes out from https://www.base64decode.org/ as:<br /></p><div class="codebox"><pre><code>%PDF-1.3
1.00 w
3 0 obj
&lt;&lt;/Type /Page
/Parent 1 0 R
/MediaBox [0 0 595.28 841.89]
/Resources 2 0 R
/Contents 4 0 R&gt;&gt;
endobj
4 0 obj
&lt;&lt;/Filter /FlateDecode /Length 1537&gt;&gt;
stream
xZ[s8~8/Lc$[O$M
Y]Ajk</code></pre></div>]]></content>
			<author>
				<name><![CDATA[apmuthu]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=364</uri>
			</author>
			<updated>2023-07-07T05:35:05Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=42404#p42404</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=42398#p42398" />
			<content type="html"><![CDATA[<p>After updating to FA 2.4.16, found that this email issue raised its head again. When I change the reporting/includes/class.mail.inc file to my changes made as indicated above, it sends correctly to me and the client. </p><p>It sends a plain coded email mail that looks like this small extract<br /></p><div class="codebox"><pre><code>JVBERi0xLjMKMS4wMCB3CjMgMCBvYmoKPDwvVHlwZSAvUGFnZQovUGFyZW50IDEgMCBSCi9N
ZWRpYUJveCBbMCAwIDU5NS4yOCA4NDEuODldCi9SZXNvdXJjZXMgMiAwIFIKL0NvbnRlbnRz
IDQgMCBSPj4KZW5kb2JqCjQgMCBvYmoKPDwvRmlsdGVyIC9GbGF0ZURlY29kZSAvTGVuZ3Ro
IDE1Mzc+PgpzdHJlYW0KeJzVWltz0zgUfu+vOC/MwkxjJFvypU8kTdoNA6W0WZZd4EHEamuw</code></pre></div><p>Nothing is attached to the email.</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2023-06-26T08:58:52Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=42398#p42398</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41862#p41862" />
			<content type="html"><![CDATA[<p>I found a solution for the reporting/includes/class.mail.inc</p><p>I have found the solutions by changing all the \n code in the file to \r\n and it works on both PHP7.4 and PHP8.0</p><p>Emails are now sending and displaying correctly when sent from FA.</p><p>\r\n is for a new line in windows as for \n in the new line in Linux. </p><p>Use \r\n instead of \n for your implode -- explicitly specifies CRLF as the line terminator.</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2022-12-19T16:22:26Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41862#p41862</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41861#p41861" />
			<content type="html"><![CDATA[<p>Out of some more research, I found the following on PHP bug tracker that might help:</p><p>A comment on PHP bug tracker also seems to enforce the fact that PHP 8 would not be tricky-compliant : https://bugs.php.net/bug.php?id=81158</p><p>This PHP issue may also be related, as it is mentioned to work with PHP 7.4 but not on PHP 8.0, because of LF char in headers : https://github.com/php/php-src/issues/7902 .</p><p>If I understand correctly, the &quot;mail&quot; function is replacing CRLF characters by LF characters, because some MTA may misinterpret CRLF and convert CRLF into CRCRLF.</p><p>I am not a programmer so I am merely trying to find a solution that could work on FA.</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2022-12-19T15:45:29Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41861#p41861</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41858#p41858" />
			<content type="html"><![CDATA[<p>I presume that FA is using the file class.mail.inc</p><p>This file has not been updated since 2004.</p><p>I am still searching to see if there is a difference between 7.4 PHP mail() function and that of PHP8.</p><p>Mail from my Joomla4 installation and plugins and Moodle 4.1 on PHP8 are all sending emails without a problem. It is only my FA that has an issue with the PHP change.</p><p>What I could trace is the following:</p><p>&quot;In PHP 8.0 there was a change to only explode email headers only on CRLF where previously it was exploded on LF and CRLF:</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2022-12-19T12:25:49Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41858#p41858</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41857#p41857" />
			<content type="html"><![CDATA[<p>I have now played around with the CPANEL PHP settings for the subaccount for FrountAccounting. There are no mail settings. I am now getting the invoice email when PHP is set to PHP8.0, but it is all in plain text, no pdf attached.</p><p>On my test client, I receive two emails, one to me as admin and one to me as the client. On PHP8 however, I either do not get anything or now just receive a client email in Text, not pdf.</p><p>I am now at the end of struggling and will have to move my FA installation to a sub-domain with PHP7.4 enabled until I have time to figure this out since for the rest of my site I need PHP8 for both Joomla and Moodle.</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2022-12-19T11:41:15Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41857#p41857</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41855#p41855" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>Braath Waate wrote:</cite><blockquote><p>Sending invoices with PHP 8 works for me, so the problem is neither FA or PHP 8.</p><p>If FA shows the invoice was mailed in green, it means that your mailer returned success.</p><p>Because you are able to send with PHP 7 and not PHP 8, you may have some differing mailer setting in your php.ini file for each version.</p><p>If the php.ini files are identical, then you need to enable debug on your system mailer to see exactly what and where the email was sent.&nbsp; You could compare the mailer debug output when running PHP 7 and PHP 8.</p><p>If there is no difference in mailer debug output, then you have run out of options to find the problem.</p><p>Sorry if this post is not of much help.</p></blockquote></div><p>Thanks, Breath will try and figure it out then.</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2022-12-19T09:37:10Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41855#p41855</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41850#p41850" />
			<content type="html"><![CDATA[<p>How do i add sales inventory location&nbsp; filter to the report 107 file</p>]]></content>
			<author>
				<name><![CDATA[b.popoola]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=46853</uri>
			</author>
			<updated>2022-12-15T11:49:57Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41850#p41850</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41849#p41849" />
			<content type="html"><![CDATA[<p>How do i add sales area filter to the report 107 file</p>]]></content>
			<author>
				<name><![CDATA[b.popoola]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=46853</uri>
			</author>
			<updated>2022-12-15T11:44:14Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41849#p41849</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41846#p41846" />
			<content type="html"><![CDATA[<p>Sending invoices with PHP 8 works for me, so the problem is neither FA or PHP 8.</p><p>If FA shows the invoice was mailed in green, it means that your mailer returned success.</p><p>Because you are able to send with PHP 7 and not PHP 8, you may have some differing mailer setting in your php.ini file for each version.</p><p>If the php.ini files are identical, then you need to enable debug on your system mailer to see exactly what and where the email was sent.&nbsp; You could compare the mailer debug output when running PHP 7 and PHP 8.</p><p>If there is no difference in mailer debug output, then you have run out of options to find the problem.</p><p>Sorry if this post is not of much help.</p>]]></content>
			<author>
				<name><![CDATA[Braath Waate]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=41493</uri>
			</author>
			<updated>2022-12-14T17:54:20Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41846#p41846</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41841#p41841" />
			<content type="html"><![CDATA[<p>FA 2.4.14 is still not sending invoices on PHP8. It shows in green that the invoice was emailed, but nothing is received. All the websites that I run have now been updated to PHP8 since PHP7 has stopped any maintenance or security issues.</p><p>Since it is showing that the invoice was sent, but nothing is received it does not show any error.</p><p>When I revert back to PHP7 it emails the invoice without issues. </p><p>There are two places where you can email the invoice, on the sales tab after you created an invoice and then from the reports tab/ Invoices/email. None of the two is sending the invoices when PHP8 is activated.</p><p>.</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2022-12-13T17:06:57Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41841#p41841</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41407#p41407" />
			<content type="html"><![CDATA[<p>enable debugging mode and get the errors displayed in PHP 8.</p>]]></content>
			<author>
				<name><![CDATA[kvvaradha]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=19348</uri>
			</author>
			<updated>2022-09-05T10:26:05Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41407#p41407</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41406#p41406" />
			<content type="html"><![CDATA[<p>PHP 8 on 2.4.12 Invoice printing and email issue. The invoice does not want to print or email. </p><p>It shows that it was emailed, but it is never received.</p><p>On print, it just hangs.</p><p>When I revert back to PHP7.4 it prints and email.</p><p>Please advise.</p>]]></content>
			<author>
				<name><![CDATA[seahawk]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=544</uri>
			</author>
			<updated>2022-09-05T07:37:35Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41406#p41406</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: PHP 8]]></title>
			<link rel="alternate" href="https://frontaccounting.com/punbb/viewtopic.php?pid=41234#p41234" />
			<content type="html"><![CDATA[<p>You are correct. I did not read the system requirement. Probably, I am too stupid to find it ;-)</p><p>All is working in a container, no errors.</p><p>Just for other readers: <br />I had one issue about the language. Inside the container I installed the dutch language pack. &quot;locale -a&quot; gives: &quot;nl_NL.utf8&quot;. Other codings are not available.<br />I opened the PO file from the FA installation and saved it with PoEdit to UTF-8 format.<br />In &quot;installed_languages.inc&quot;, I changed the encoding to &quot;UTF-8&quot;. Now the dutch language is working in FA.</p>]]></content>
			<author>
				<name><![CDATA[Zilvermeeuw]]></name>
				<uri>https://frontaccounting.com/punbb/profile.php?id=17887</uri>
			</author>
			<updated>2022-07-06T15:25:34Z</updated>
			<id>https://frontaccounting.com/punbb/viewtopic.php?pid=41234#p41234</id>
		</entry>
</feed>
