Jump to content

[SOLVED] lightbox


emediastudios

Recommended Posts

Hi everyone.

A simple one, never the lesss doing my head in

<a href=images/applications/".$info[picname]." rel=lightbox>

I cant get it to work, in the source code of the site it looks as above, and lightbox dont work. It should look like this in the page source

<a href=images/applications/".$info[picname]."rel="lightbox">

 

but i get errors when i put the "" around lightbox

I tried putting slashes there and no luck

 

Link to comment
https://forums.phpfreaks.com/topic/139841-solved-lightbox/
Share on other sites

yeah thats all there. here is all the code.

<?PHP
$content .= "<td valign=\"bottom\"><br><a href='admin.php?p=temp_models&id=".$info[tempmodelid]."'><strong>Delete this application</strong></a><br>".$info[name]."<br><a href='mailto:".$info[email]."?subject=Jimmys Promotions and Modelling Agency Model Application'>".$info[email]."</a><br><a href=images/applications/".$info[picname]."rel=lightbox><img src='images/applications/".$info[picname]."' alt='".$info[name]."' width='300'/><a/><br><br></td>";
?>

 

Link to comment
https://forums.phpfreaks.com/topic/139841-solved-lightbox/#findComment-731574
Share on other sites

<?PHP
$content .= "<td valign=\"bottom\"><br><a href='admin.php?p=temp_models&id=".$info[tempmodelid]."'><strong>Delete this application</strong></a><br>".$info[name]."<br><a href='mailto:".$info[email]."?subject=Jimmys Promotions and Modelling Agency Model Application'>".$info[email]."</a><br>
<a href='images/applications/'".$info[picname]." rel='lightbox'><img src='images/applications/".$info[picname]."' alt='".$info[name]."' width='300'/><a/><br><br></td>";
?>

Link to comment
https://forums.phpfreaks.com/topic/139841-solved-lightbox/#findComment-731640
Share on other sites

I would suggest sticking to 1 set of quotes and staying that way, you go in and out different times with different quotes.

 

<?php
$content .= '<td valign="bottom"><br><a href="admin.php?p=temp_models&id='.$info['tempmodelid'].'"><strong>Delete this application</strong></a><br>'.$info['name'].'<br><a href="mailto:'.$info['email'].'?subject=Jimmys Promotions and Modelling Agency Model Application">'.$info['email'].'</a><br><a href=images/applications/'.$info['picname'].' rel="lightbox"><img src="images/applications/'.$info['picname'].'" alt="'.$info['name'].'" width="300" /><a/><br><br></td>';
?>

 

You will also notice I put ' around the array indexes to avoid the "undefined constant" notice.

Link to comment
https://forums.phpfreaks.com/topic/139841-solved-lightbox/#findComment-732072
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.