0
	
	
								For 3 days, I'm trying to find out why sending mail does not work. Php mail function is fine. Sends orders in the order. Admin tools also.
GET https://domena.cz/administrator/index.php?option=com_invoices&controller=invoice&task=send_email&cid[]=25&ajax=1&type=1&_=1520156766602
Failed to load resource: the server responded with a status of 500 ()
							
							
							
		
									
							GET https://domena.cz/administrator/index.php?option=com_invoices&controller=invoice&task=send_email&cid[]=25&ajax=1&type=1&_=1520156766602
Failed to load resource: the server responded with a status of 500 ()
Responses (10)
							
								- 
						
	
	Accepted Answer
- 
						
	
	Accepted Answer
- 
						
	
	Accepted Answer
- 
						
	
	Accepted Answer
- 
						
	
	Accepted Answer0Is the problem here?
 if($params->get('pdfemail') && InvoicesHelper::PDFavailable()){
 //create PDF
 $viewpdf = $this->getInvoiceView('dompdf');
 
 $viewpdf->invoice = $view->invoice ;
 $viewpdf->template = $this->getTemplate();
 $viewpdf->items = $view->items ;
 $viewpdf->taxes = $view->taxes ;
 $viewpdf->payments = $view->payments;
 $viewpdf->payments2 = $view->payments2;
 $viewpdf->params = $params;
 
 if($viewpdf->template->content_pdf) $viewpdf->template->content = $viewpdf->template->content_pdf ;
 
 $viewpdf->_path['template'][1] = JPATH_SITE.DS.'components'.DS.'com_invoices'.DS.'views'.DS.'invoice'.DS.'tmpl' ;
 
 if($viewpdf->invoice->invoice_num) $pdfname = $viewpdf->invoice->invoice_num;
 else $pdfname = rand();
 
 $location = JPATH_SITE.DS.$params->get('pdffolder','pdfinvoices').DS.$pdfname . ".pdf" ;
 $pdf = $viewpdf->storepdf($location);
 
 if($pdf) $mail->addAttachment($location, $viewpdf->invoice->invoice_num . ".pdf") ;
 
 }
- 
						
	
	Accepted Answer
- 
						
	
	Accepted Answer
Your Reply
			 
				Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here.
Register Here » 
					
				