I'm trying to show specific extra field in a modal box. I'm creating a variable in item.php with "$custom = $this->item->extra_fields;" and then i can display any extra field inside the template with "<?php echo $custom[0]->value; ?>". But when i try to call the field in a modal box there is a problem.
If i try this: "<a href="<?php echo $custom[0]->value; ?>" rel="{handler:'iframe',size:{x:990,y:650}}" class="modal">Custom Field</a>" i'm getting a Bad request error.
If i try this: "<a href="#<?php echo $custom[0]->value; ?>&tmpl=component" rel="{handler:'iframe',size:{x:990,y:650}}" class="modal">Custom Field</a>" the modal box is displaying the whole page with all the modules and the template.
The field is displaying ok inside the template between div tags, but not in a modal box.
Can someone help me i don't know what i'm doing wrong?