brettacvh wrote:After putting this code in, the browser displays a blank page, with no errors.
Test with this script:
<?php
$row = '1,2';
foreach (explode(',', $row) as $value) {
echo '../images/tick' . $value . '.gif' . "<br />\n";
}
If you do not get this output:
../images/tick1.gif
../images/tick2.gif
then something is wrong with your server configuration.
brettacvh wrote:Is something like this closer?
No. It is terribly clumsy and inflexible to try and anticipate the possible values like that, and substr_count() can double count, e.g., a string containing '12' could be interpreted as containing '1', '2' and '12'.