Jump to content

heredoc StringProblems


mmerril1

Recommended Posts

Hi again

 

cannot figure out why this line of code with not work

 

Parse error: syntax error, unexpected T_SL

error on line 3

 

if ($_POST[web] != ""){
$title = <<<TEST 
<a class="active" href="http://$_POST[web]" target="_blank">$_POST[bname]</a><br>
TEST;
} else { 
$title = <<<TEST 
<font class="nosite">$_POST[bname]</font><br>
TEST;
}

Link to comment
https://forums.phpfreaks.com/topic/139636-heredoc-stringproblems/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.