Forum Moderators: coopster
Any assistance appreciated. An explaination would help me learn... I have been unable to find any book that explains it.
echo '<div class="econ"><a href="#" onClick="eleopen(event,"' . PDOC_PATH . '013.php")" onMouseOut="ess.close()"><img src="' . PIMG_PATH . '013.jpg" width="123" height="151" alt="13"></a></div>';
Basically, you're concatenating 5 string values together:
'<div...,"'
PDOC_PATH
'013.php...src="'
PIMG_PATH
'013.jpg...</div>'
The stuff between matching single-quotes (') can be anything. PHP doesn't care, it will concatenate all the strings together and send the result as is to the browser, whether it's HTML, javascript, or anything else. See the doc on Single quoted strings [php.net]
Constants are used like variables, except they're not preceded by the $ sign. See the doc on constants [php.net]
Hope this helps.