I am using a colorbox.
<a class="publishpost" href="<?= base_url()."publish_ads/publishon/".$adds[$i]->getId()?>"></a>
<script>
$(document).ready(function(){
$('.publishpost').colorbox({ width: '900px', height: '500px' });
});
</script>
I have this link that points to a codeigniter controller. I would like to access some variable from the view in which I load the colorbox. How can I do this. I thought about a form or maybe something with jquery but I still dont know how pass the parametres.
The values that I intend to pass as parametres are something like this for example:
<div class="external_wall_right_col_sub_ad_img"><img src="<?=$img?>" alt="small ad"></div>
I want to pass the $img variable to the colorbox.