Pages, Articles & News
Tools & Plugins
Example / Placeholder Title


Description as an example placeholder. Sample text content for further customization of the "Index36" template.

You are free to edit and customize the template however you like. If you don’t have time or enough knowledge — you can always order template adaptation by contacting me via GitHub or private messages on the digital goods marketplace.

2024-11-08 09:56
Avatar" alt="" class="rounded-circle border border-2 border-light" width="54" height="54">

В связке с "phpmailer" может выскочить ошибка:

Warning: trim() expects parameter 1 to be string, array given in  ../plugins/phpmailer/src/PHPMailer.php on line 1086

не знаю правильно или нет, но на быструю решил так.

открываем файл:

.../plugins/contact/contact.php

в районе 102-й строки находим код:

            cot_mail(
                [
                    'to' => $semail,
                    'from' => [$rcontact['contact_email'], $rcontact['contact_author']]
                ],
                $rcontact['contact_subject'],
                $rtextm
            );

меняем его полностью на

			if (cot_plugin_active('phpmailer')) {
				$semail = Cot::$cfg['plugin']['contact']['email'];
				$toOrOther = $semail;
					if(stristr($_SERVER['SERVER_NAME'], 'localhost') === FALSE){	
						cot_mail($semail, 'Форма обратной связи', $_SERVER['SERVER_NAME'] . "\n\n" . 'Проверьте сообщения в адмике из формы обратной связи.');	
					}
				} 
			else 
			{
				cot_mail(
					[
						'to' => $semail,
						'from' => [$rcontact['contact_email'], $rcontact['contact_author']]
					],
					$rcontact['contact_subject'],
					$rtextm
				);
			}

 

 

This post was edited by webitproff (2024-11-08 10:10, 1 year ago)
Account