no_img.gif 파일 불러 오려면 어떻게 하나요? 정보
no_img.gif 파일 불러 오려면 어떻게 하나요?본문
캘러리 리스트에서 이미지 첨부가안된건 엑스박스가아니고 설정한 노이미지파일을 불러 오게 하고 싶은데 어떻게 하면 될까요?
소스는 아래와 같습니다..
<?
if ($list[$i]['link'][1] != "") {
?>
<a href="<?=$list[$i]['link'][1]?>" target="_blank"><img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="198" height="128" border="0"></a>
<?
}
else {
?>
<img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="200" height="130">
<?
}
?>
소스는 아래와 같습니다..
<?
if ($list[$i]['link'][1] != "") {
?>
<a href="<?=$list[$i]['link'][1]?>" target="_blank"><img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="198" height="128" border="0"></a>
<?
}
else {
?>
<img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="200" height="130">
<?
}
?>
댓글 전체

if ($list[$i]['link'][1] != "") {
?>
<a href="<?=$list[$i]['link'][1]?>" target="_blank"><img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="198" height="128" border="0"></a>
<?
}
else {
?>
<img src="no_img.gif " width="200" height="130">
<?
}
?>
<a href="<?=$list[$i]['link'][1]?>" target="_blank"><img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="198" height="128" border="0"></a>
<?
}
else {
?>
<img src="no_img.gif " width="200" height="130">
<?
}
처음에 그렇게 했는데 안되요...
<a href="<?=$list[$i]['link'][1]?>" target="_blank"><img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="198" height="128" border="0"></a>
위에 바로 위에 소스는 적용이 안됩니다.. 무용지물... 아래 소스를 바꾸면 이미지가 다 안나타남
<a href="<?=$list[$i]['link'][1]?>" target="_blank"><img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="198" height="128" border="0"></a>
위에 바로 위에 소스는 적용이 안됩니다.. 무용지물... 아래 소스를 바꾸면 이미지가 다 안나타남
맨 위에 소스를 제가 잘못 올렸네요 아래 소스를 바꿔야 할듯 해요...
<?
if ($list[$i]['link'][1] != "") {
?>
<?
}
{
?><a href='<?=$list[$i][href]?>'>
<img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="100" height="70"></a>
<?
}
?>
<?
if ($list[$i]['link'][1] != "") {
?>
<?
}
{
?><a href='<?=$list[$i][href]?>'>
<img src="<?=$list[$i]['file'][0]['path']?>/<?=$list[$i]['file'][0]['file']?>" width="100" height="70"></a>
<?
}
?>

$sql = " select bf_file from $g4[board_file_table] where bo_table = '$bo_table' and wr_id = '{$list[$i]['wr_id']}' and bf_type in (1,2,3) ";
$data = sql_fetch($sql);
if ($data['bf_file']) {
echo "<img src='".$g4['path']."/data/".$bo_table."/".$data['bf_file']."'>";
} else {
echo "<img src='noimage.gif'>";
}
$data = sql_fetch($sql);
if ($data['bf_file']) {
echo "<img src='".$g4['path']."/data/".$bo_table."/".$data['bf_file']."'>";
} else {
echo "<img src='noimage.gif'>";
}