I'm trying to display a image from MySQL and it works like this:
echo "<tbody>";
echo "<tr>";
echo "<td>$linha[receita_id]";
echo '<td><img src="data:image/jpeg;base64,'.base64_encode( $linha['image'] ).'"/>';
echo "</tr>";
echo "</tbody>";
What I want to do it to use php echo <<<_END
because I have a lot more lines of code, and I don't want to type lots of "echo" for every line.
So I have this below, but It doesn't work! I tryed all types of different escape characters, but still nothing.
echo <<<_END
<tbody>
<tr>
<td>$linha[receita_id]
<td><img src="data:image/jpeg;base64,'.base64_encode( $linha[image] ).'"/>
</tr>
</tbody>
_END;
The line with $linha[receita_id]
works perfectly! But the other doesn't.
Any ideas?