Copy link to clipboard
Copied
I'm hoping someone can point me in the right direction here. I have set-up a master & detail page from a recordset and it is working as it should, however my client would like to have the details show up in a lightbox instead of going to another page. How can I accomplish this? I have a lightbox that I am using called pretty photo... which is also working, I just am looking for a way to have them work together.
Thanks,
Bret
Copy link to clipboard
Copied
Echo your PHP data using inline code for Prettyphoto as HTML.
<a href="#inline-1" rel="prettyPhoto" >Click to view details</a>
<div id="inline-1" class="hide">
<p>This is inline content opened in prettyPhoto.</p>
<p>ECHO HERE</p></div>
</div>
Copy link to clipboard
Copied
Thank you! that is getting me there I think I did change a couple things.... although I am still not sure how to tie the two links together.
<a href="#inline-1" rel="prettyPhoto[inline]">Click to view details </a>
<div id="inline-1" style="display:none;">
<p>This is inline content opened in prettyPhoto.</p>
<p>ECHO HERE</p>
</div>
This is inline content opened in prettyPhoto.
ECHO HERE
This is the current link that redirects to a new page showing all info from recordset:
<a href="staffDetail.php?recordID=<?php echo $row_rsStaffMaster['staffID']; ?>"> <?php echo $row_rsStaffMaster['lastName']; ?></a>
What I need is the current link to display into the lightbox. How do I seperate the echo and still keep the staffID part?

Thanks
UPDATE:
Ok so I have updated the link this way...
<a href="#inline-1 staffDetail.php?recordID=<?php echo $row_rsStaffMaster['staffID']; ?> "rel="prettyPhoto[inline]"><?php echo $row_rsStaffMaster['lastName'];?></a>
<div id="inline-1" style="display:none;">
<p>This is inline content opened in prettyPhoto.</p>
<p>ECHO HERE</p>
</div>
And this now open the lightbox... but all it does is give me a tiny lightbox of content | null

Would I add my - staffdetailspage code & recordset to the ?
<p>ECHO HERE</p>
Copy link to clipboard
Copied
Define a variable value for your details URL (name it contenturl). Then define a variable to fetch contents from the variable URL with file_get_content (name it content).
Echo content within <p>ECHO HERE</p> section.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now