WP Thickbox Integration

This WordPress plugin integrate easily Thickbox into your front-end blogs.

The  “thickbox” class name is included into your image tag without touching the html. You can select an option “Open in the same window” on the Edit Image Panel.

You can include the Thickbox parameters to the URL on the Link Url field like this example to open an iframe:
Link Url: http://web-argument.com/?KeepThis=true&TB_iframe=true&height=400&width=600

WordPress Galleries are automatically set for use Thickbox, so you just need to insert the “gallery” into your post and the “class” name and “rel” tag will be included.

The plugin uses the wordpress back-end “jquery” and “thickbox” javascript files to maximaze themes and plugins compatibilities.

Download the plugin here.

Wp Thickbox Integration

Support our project, leave your comments or make a donation.

29 thoughts on “WP Thickbox Integration”

  1. Found a better kludge. Still have tocomment out lines 8 and 9 in thickbox.js but instead of modifying the header.php and admin-header.php files just add the following code the the function add_tickbox_integration_css()

    $tpi_header = “\n<!– Default Thickbox Paths –>\n”;
    $tpi_header .= “<script type=\”text/javascript\”>\n”;
    $tpi_header .= “\t var tb_pathToImage=\””.”../wp-includes/js/thickbox/loadingAnimation.gif\”;\n”;
    $tpi_header .= “\t var tb_closeImage=\””.”../wp-includes/js/thickbox/tb-close.png\”;\n”;
    $tpi_header .= “</script>\n”;
    echo $tpi_header;

    This seems to allow the plugin to work with wordpress 2.8.4 when creating a gallery.

  2. I am using wordpress 2.8.4 and version 1.0.1 of your plugin and ran into a serious problem trying to use your plugin. Basically the redefinition of the variables tb_pathToImage and tb_closeImage by thickbox_path_int() was being ignored by the wordpress thickbox code. Commenting out lines 8 and 9 in thickbox.js made the plugin work for a gallery but broke the admin use of thickbox. Don’t know why this happens as it looks like it shoild work! Perhaps you have some ideas.

    I used the following kludge to fix it for my purposes:

    1. Comment out lines 8 and 9 in thickbox.js
    2. Add the following code to the head section of the header.php and admin-header.php files:
    <?php
    $tpi_header = “\n\n”;
    $tpi_header .= “\n”;
    $tpi_header .= “\t var tb_pathToImage=\””.”../wp-includes/js/thickbox/loadingAnimation.gif\”;\n”;
    $tpi_header .= “\t var tb_closeImage=\””.”../wp-includes/js/thickbox/tb-close.png\”;\n”;
    $tpi_header .= “\n”;
    echo $tpi_header;
    ?>

    This seems to allow the plugin to work in both the admin section (but I’ve only done limited testing) and the public section.

  3. Hi, I’m already including jQuery in my pages. Your plugin also includes an older version of jQuery. Is there a way to disable that?

Leave a Reply

Your email address will not be published. Required fields are marked *