Jump to content

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

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.