Jump to content

Href Not Wrapping Around Image Function


White_Lily

Recommended Posts

Hi i have a slight problem, in my if and else statement that checks whether or not there is an image in the database when there is an image, there is a href tag that wraps around image the image so that once the image is clicked it then does a lightbox effect.

 

the problem im having is that when there IS an image, the href tag is NOT wrapping around the image.

 

<?php
if(!$res["image"]){
 echo 'No Image';
}else{
 echo '<a href="'.$res["image"].'" rel="lightbox">'.displayImage($res["image"], $res["name"], NULL, 150, 150).'</a>';
}
?>

Link to comment
https://forums.phpfreaks.com/topic/268778-href-not-wrapping-around-image-function/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.