Page 1 of 1
what do EOC; ?
Posted: Thu Sep 01, 2005 10:35 am
by mtc9003
What do EOC; ?
Posted: Mon Sep 05, 2005 2:56 pm
by Klemen
They end printing out code block.
For example:
Code: Select all
echo <<<EOC
<br>
<b>asfasf</b>
<br>
<hr>
<p>
EOC;
would print out this to the browser:
<br>
<b>asfasf</b>
<br>
<hr>
<p>
Regards
Re:
Posted: Wed Jan 28, 2015 2:02 am
by capeloyo
Klemen wrote:They end printing out code block.
For example:
Code: Select all
echo <<<EOC
<br>
<b>asfasf</b>
<br>
<hr>
<p>
EOC;
would print out this to the browser:
<br>
<b>asfasf</b>
<br>
<hr>
<p>
Regards
Hi Klemen..
About EOC in ver 2.5.. Previously i'm using ver 2.3 and want to up grade, the issue is..
echo <<<EOC
<tr title="$ticket[message]">
<td class="$color" style="text-align:left; white-space:;"><a?track=$ticket[dt]&Refresh=$random">$ticket[dt]</a></td>
EOC;
how do i put : <td>'.hesk_date($ticket['dt'], true).'</td>in EOC.
bcoz i want date like this : 10-Oct-2012 11:36am
instead this 2015-01-27 15:48:32 by using <td>'.hesk_date($ticket['dt'], true).'</td>
Thank You.
Sorry if you difficult to understand my question.
Re: what do EOC; ?
Posted: Wed Jan 28, 2015 1:38 pm
by Klemen
You can't use function calls inside EOC block.
You will need to format the variable first:
Code: Select all
$ticket['dt'] = hesk_date($ticket['dt'], true);
Then use $ticket[dt] inside EOC.
Re: what do EOC; ?
Posted: Thu Jan 29, 2015 8:16 am
by capeloyo
Klemen wrote:You can't use function calls inside EOC block.
You will need to format the variable first:
Code: Select all
$ticket['dt'] = hesk_date($ticket['dt'], true);
Then use $ticket[dt] inside EOC.
Hi Klemen..
Success! Thank you for the generous contribution!
