Well...
I need to be able to have a large block of HTML code inside a PHP
document, assign it a variable, and use other variables, functions, and
objects within the HTML code still.
Clarification:
I have the following code (as an example):
$variable = <<<HTML
<table>
<tr><td>$text</td></tr>
<tr><td>echo $config->getBlah()</td></tr>
</table>
HTML;
I need to be able to do that ^, that actual code wouldn't work, but it
is an example of what I need to do. I have tried searching for the <<<
operator, or whatever it is, the problem is most search utilities won't
recognize <<<, so it is really really hard to search and find answers
about it, I can't find anything about it on the php manual, I'm falling
onto a last resort by posting on some forums to see if anyong is able
to help me.
So question being really:
Is there a way I can split that so it recognizes those lines as PHP and
not part of the block of HTML code
OR
Is there another method that I can use to achieve this same effect ?
I have to be able to keep the block of code together, not seperating
each line into a variable declaration. such as:
$var = "<tr><td>" . $text . "</td></tr>";
$var .= "<tr><td>" . echo $config->getBlah(); . "</td></tr>";
Do NOT want to do that.
So if anyone has any ideas/solutions, please, please let me know :)
Thanks.