-1

当我单击此处的缩略图时,为什么在大照片下出现未定义,如何解决此问题?我试过把这里的所有东西都注释掉没有效果?以下是代码和供审查的 URL:

http://tinyurl.com/6pbkhg7

<td><div id="loadarea" style="width: 400px; height: 300px;">
<img width="400" height="300" src="http://www.mydomain.com/feeds/fmfl/rets_images/<?php echo(rawurlencode($row['ListingRid'])); ?>_1.jpg" alt="<?php echo(rawurlencode($row['MLNumber'])); ?>" align="left"  border="0">
</div>

<?
$image = "<br>";
$ListingRid = $row['ListingRid'];
$img_cnt = 1;
//$image .= "<a href=/feeds/fmfl/rets_images/{$ListingRid}_1.jpg rel=\"enlargeimage\" rev=\"targetdiv:loadarea,trigger:click\"><img src=/feeds/fmfl/rets_images/{$ListingRid}_1.jpg alt='' width='100' height='75' border='0' /></a>&nbsp;";
for ($c=1;$c<10;$c++) {
    if ($c<10)
        $c_ext = $c;
    else
        $c_ext = $c;

    if (file_get_contents("http://www.mydomain.com/feeds/fmfl/rets_images/{$ListingRid}_{$c_ext}.jpg"))
        $image .= "<a href=/feeds/fmfl/rets_images/{$ListingRid}_{$c_ext}.jpg rel=\"enlargeimage\" rev=\"targetdiv:loadarea,trigger:click\"><img src=/feeds/fmfl/rets_images/{$ListingRid}_{$c_ext}.jpg alt='' width='100' height='75' border='0' /></a>&nbsp;";
    else
        $c=12;
    $img_cnt++;
    if ($img_cnt == 5) {
        $image .= "<br>";
        $img_cnt = 0;
    }

}

?>
4

1 回答 1

2

因为您缺少标题标签

试试这个标题:

$image .= "<a href=/feeds/fmfl/rets_images/{$ListingRid}_{$c_ext}.jpg rel=\"enlargeimage\" rev=\"targetdiv:loadarea,trigger:click\" title=\"THIS IS TITLE\"><img src=/feeds/fmfl/rets_images/{$ListingRid}_{$c_ext}.jpg alt='' width='100' height='75' border='0' /></a>&nbsp;";

或者这个没有标题:

$image .= "<a href=/feeds/fmfl/rets_images/{$ListingRid}_{$c_ext}.jpg rel=\"enlargeimage\" rev=\"targetdiv:loadarea,trigger:click\" title=\"\"><img src=/feeds/fmfl/rets_images/{$ListingRid}_{$c_ext}.jpg alt='' width='100' height='75' border='0' /></a>&nbsp;";

灯箱需要一个标题,title=""如果你不想要任何东西,你应该设置。

于 2012-05-04T10:00:44.797 回答