PHP echo inside input dont work?

Viewed 3043
<input name="name" type="text"  
       id="nome" size="45"  maxlength="35" value=<?php echo "need help" ?>/> 

// output "need" but i expect "need help"

it was a POST var string of a name, but just out puts the fist name, then i realised the echo or print do not work with whitespace inside the tag value, like echo do outside

what the solution to "need help"??

3 Answers

In MVC you can do something like this

<input name="name" type="text"  
       id="nome" size="45"  maxlength="35" value="{{$person->island}}"/> 
Related