[SOLVED] Edit record in a lightbox

skittle 18 Jun, 2013
I have read 24 pages of lightbox posts on the forum. I have reviewed the tutorials. But I am still not sure how to open a record in a lightbox for editing!

I am using the latest versions of Chronoforms and Chronoconnectivity. I have a developed a Chronoconnectivty view using the the Custom Code option under frontend listings. From there I have successfully implemented links to edit each record that appears in the listing. I have used
<td style='font-size:12px; text-align: left !important';><a class= href="http://mysite.com/index.php?option=com_chronoconnectivity&view=connection&Itemid=125&task=cc_edit_data&cid=<?php echo $cfid;?>">Edit Normal</a></td>
and everything works perfectly.

Now, what I really want to do is to have the form I am using for editing appear in a lightbox. So after reading the excellent tutorials, I configured my form to run in a lightbox. I came up with this for linking my form.
<td style='font-size:12px; text-align: left !important';><a class="modal" href="index.php?option=com_chronoforms&chronoform=AirframeCurrentStatus&tmpl=component" rel="{handler: 'iframe', size: {x: 1000, y: 310}}">Add LB</a></td>
This works perfectly and displays my form in a lightbox.

So the next step is to get the form in the lightbox to load the record for editing just like my non-lightbox form. I have tried the obvious but this just isn't working.
<td style='font-size:12px; text-align: left !important';><a class="modal" href="index.php?option=com_chronoforms&chronoform=AirframeCurrentStatus&tmpl=component&task=cc_edit_data&cid=<?php echo $cfid;?>" rel="{handler: 'iframe', size: {x: 1000, y: 310}}">Edit LB</a></td>

Any help/suggestions would be greatly appreciated!

Thanks for a great product and excellent support!

John
GreyHead 19 Jun, 2013
HI skittle,

I'm not clear where $cfid comes from but there are obvious differences in the URLs that you are using:
http://mysite.com/index.php?option=com_chronoconnectivity&view=connection&Itemid=125&task=cc_edit_data&cid=<?php echo $cfid;?>
and
index.php?option=com_chronoforms&chronoform=AirframeCurrentStatus&tmpl=component&task=cc_edit_data&cid=<?php echo $cfid;?>
The first is a CC URL, the second is a ChronoForms one. Have you tried:
index.php?option=com_chronoconnectivity&view=connection&Itemid=125&tmpl=component&task=cc_edit_data&cid=<?php echo $cfid;?>


Bob
skittle 20 Jun, 2013
Thank you very much! Works perfectly.

I'm buying this round. Enjoy your beers!

John
GreyHead 20 Jun, 2013
Hi John,

Thank you, much appreciated.

Bob
This topic is locked and no more replies can be posted.