html value to php variable code example
Example 1: use php variable in html attributes
<span title="<?php echo htmlspecialchars($variable); ?>">
Example 2: set php var to html
<?php ob_start();?>
<div>Contents goes <b>here</b></div>
<?php $contents=ob_get_clean();?>