1

I'm writing an admin plugin which produces a pop up to give the user a preview of content.

I tried to use thickbox as suggested here - http://codex.wordpress.org/ThickBox but it does not respect dimensions.

My questions are - is this just broken, should i go custom, or is there now a better way to do this?

Thanks in advance,

 <?php add_thickbox(); ?>
 <a href='#TB_inline?width=400&height=400&inlineId=preview' class='thickbox'>View all<a>";
 <div id='preview' style='display:none;'></div>
0

1 Answer 1

0
    <?php
    function wpse_1234() {
    add_thickbox();
    }
    add_action('init','wpse_1234');

    ?>
<a href='#TB_inline?height=300&amp;width=400&amp;inlineId=preview' class='thickbox'>View all<a>";
 <div id='preview' style='display:none;'></div>

Try this way it should work for thickbox.you can call those thickbox in a init hook.

Thanks.

Not the answer you're looking for? Browse other questions tagged or ask your own question.