Hi
I am trying to get the rotating images to show the thumbnail, if using just one source of thumbnail URL, no problem with that.
But when I have 2 or more different source of thumbnail URL, it does not work. Here is the code:
Code:
preg_match('(src=[\"a-z:\/\.\?=\-0-9A-Z_\"]*)',$code,$results);
$src = substr($results[0],5,strlen($result[0])-1);
preg_match('(file=[\"a-z:\/\.\?=\-0-9A-Z_\"]*)',$code,$results);
$file = substr($results[0],5,strlen($result[0])-1);
print "<thumbnail_url>";
print "$src";
print "/default.jpg";
print "</thumbnail_url>\n";
The first thumbnail source is $src and the second is $file. Without using the $file, I have no problem displaying the thumbnail.
I tried to repeat the print $file for the second thumbnail, it turns out blank. Anyone can let me know if there is a way to detect if it is $src or $file so it can display the thumbnail ?
I am still learning database. Sorry if this question is a little silly as my knowledge is very limited.
Thank you.