PHP Convert Datetime DB fields to timespan

< ?php $curentdate=mktime(date("h"), date("i"), date("s"), date("m") , date("d"), date("Y")); $curentdatestart=mktime(date("h",strtotime($row_ekpompes['ext_series_trailer_startdate'])), date("i",strtotime($row_ekpompes['ext_series_trailer_startdate'])), date("s",strtotime($row_ekpompes['ext_series_trailer_startdate'])), date("m",strtotime($row_ekpompes['ext_series_trailer_startdate'])) , date("d",strtotime($row_ekpompes['ext_series_trailer_startdate'])), date("Y",strtotime($row_ekpompes['ext_series_trailer_startdate']))); $curentdateend=mktime(date("h",strtotime($row_ekpompes['ext_series_trailer_enddate'])), date("i",strtotime($row_ekpompes['ext_series_trailer_enddate'])), date("s",strtotime($row_ekpompes['ext_series_trailer_enddate'])), date("m",strtotime($row_ekpompes['ext_series_trailer_enddate'])) , date("d",strtotime($row_ekpompes['ext_series_trailer_enddate'])), date("Y",strtotime($row_ekpompes['ext_series_trailer_enddate']))); // strtotime if($row_ekpompes['ext_series_trailer_startdate']!=null && $row_ekpompes['ext_series_trailer_enddate']!=null && $row_ekpompes['ext_series_trailer']!=null){ if($curentdatestart=$curentdate ){ $video=$row_ekpompes['ext_series_trailer']; }else { $video=$row_ekpompes['ext_trailer']; } }else { $video=$row_ekpompes['ext_trailer']; } echo $video."===="; echo date('h:i:s / m/d/y'); echo "===".$curentdate."---".$curentdatestart."---".$curentdateend; echo $row_now['ext_trailer']."----"; echo $row_now['ext_series_trailer']."----"; echo $row_now['ext_series_trailer_startdate']."----"; …

Mail php headers

$to = ‘info@eee.com’; $headers = “MIME-Version: 1.0\n”; $headers .= “Content-type: text/html; charset=utf-8\n”; $headers .= ‘From:info@eee.com’. “\r\n” .              ‘Bcc: eee@eee.gr’ . “\r\n” .              ‘Bcc: eee@eee.gr’ . “\r\n”; $headers .= “Reply-To:eee\n”;  $headers .= “X-Priority: 1\n”; $headers .= “X-mailer: DAUMED\n”;  $headers .= “X-MSmail-Priority: High\n”; $subject=”eee Contact …

php – while loop

$brush_price = 5; $counter = 10; echo “<table border=\”1\” align=\”center\”>”; echo “<tr><th>Quantity</th>”; echo “<th>Price</th></tr>”; while ( $counter <= 100 ) { echo “<tr><td>”; echo $counter; echo “</td><td>”; echo $brush_price * $counter; echo “</td></tr>”; $counter = $counter + 10; } echo “</table>”; example 2 <?php /* example 1 */ $i = 1; while ($i <= 10) {     echo $i++;  /* the printed value would be                    $i before the increment                    (post-increment) */ } /* example 2 */ $i = 1; while ($i <= 10):     echo $i; …

Page break with php-fckeditor

php code <?php if (stripos($row_latestnews[‘nws_text_gr’],”<div style=\”page-break-after: always;\”><span style=\”display: none;\”>&nbsp;</span></div>”)<1) echo substr($row_latestnews[‘nws_text_gr’],0,180); else { $str=split(“<div style=\”page-break-after: always;\”><span style=\”display: none;\”>&nbsp;</span></div>”,$row_latestnews[‘nws_text_gr’]); echo $str[0]; } ?>

\common\KT_functions.inc.php on line 464 – Cannot modify header information – headers already sent

Warning: Cannot modify header information – headers already sent by (output started at #:\#######\htdocs\####\Connections\##_cp_UTF.php:2) in #:\#######\htdocs\####\includes\common\KT_functions.inc.php on line 464 in this error please include on top of the page the MXI/mxi.php files  <?php require_once (‘includes/mxi/MXI.php’); ?>