Plugin Directory

Changeset 578236


Ignore:
Timestamp:
07/27/2012 09:54:44 PM (14 years ago)
Author:
dyerware
Message:

Checking in 1.3 gac

Location:
gallery-and-caption/trunk
Files:
2 added
2 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • gallery-and-caption/trunk/gallery-and-caption.php

    r429775 r578236  
    22/*
    33Plugin Name: Gallery And Caption
    4 Version: 1.2
     4Version: 1.3
    55Plugin URI: http://www.dyerware.com/main/products/gallery-and-caption
    66Description: Transparently upgrades your site's native galleries and captions with attractive image viewing and navigation.  Adds caption grouping to create containers of sub-galleries from your posts.   Disabling the plugin will return to the original WordPress behavior. 
     
    88Author URI: http://www.dyerware.com
    99*/
    10 /*  Copyright © 2010, 2011  dyerware
     10/*  Copyright © 2010, 2011, 2012  dyerware
    1111    Support: support@dyerware.com
    1212
     
    5757    {
    5858       $jsDir = plugins_url ( plugin_basename ( dirname ( __FILE__ ) ) ) . '/fancybox/'; 
    59        wp_register_script('dyerware-gac-fancybox', "{$jsDir}jquery.fancybox-1.3.4.1.pack.js");
     59       wp_register_script('dyerware-gac-fancybox', "{$jsDir}jquery.fancybox-1.3.4.pack.js");
    6060       wp_register_script('dyerware-gac-easing', "{$jsDir}jquery.easing-1.3.pack.js");
    6161       
     
    6969           
    7070            if (strpos($_SERVER['REQUEST_URI'], 'post.php') || strpos($_SERVER['REQUEST_URI'], 'post-new.php') || strpos($_SERVER['REQUEST_URI'], 'page-new.php') || strpos($_SERVER['REQUEST_URI'], 'page.php') || strpos($_SERVER['REQUEST_URI'], 'comment.php')) {
    71                 add_action('admin_footer', array(&$this, 'init_html_editor_tags'));
     71                //add_action('admin_footer', array(&$this, 'init_html_editor_tags'));
     72                add_action('admin_print_footer_scripts', array(&$this, 'init_html_editor_tags'), 100 );
    7273            } 
    7374       }                   
     
    224225            echo '<script type="text/javascript">';
    225226?>
     227
    226228if (gac_edbar=document.getElementById("ed_toolbar") )
    227229{
     
    243245        gac_edbar.appendChild(gac_But);
    244246    }
     247}
     248
     249else if (typeof QTags!="undefined")
     250{
     251    QTags.addButton( 'dyerware_gac', 'Captions', '[captiongroup]', '[/captiongroup]', '' );
    245252}
    246253<?php
     
    322329    function do_caption_shortcode($attr, $content = null)
    323330    {
     331        // New-style shortcode with the caption inside the shortcode with the link and image tags.
     332        if ( ! isset( $attr['caption'] ) ) {
     333             if ( preg_match( '#((?:<a [^>]+>\s*)?<img [^>]+>(?:\s*</a>)?)(.*)#is', $content, $matches ) ) {
     334                  $content = $matches[1];
     335                  $attr['caption'] = trim( $matches[2] );
     336             }
     337        }
     338
    324339        // Allow plugins/themes to override the default caption template.
    325340        $output = apply_filters('img_caption_shortcode', '', $attr, $content);
     
    344359        $xml=simplexml_import_dom($doc);
    345360        $links=$xml->xpath('//a');
     361       
    346362        foreach ($links as $a)
    347363        {
     
    375391                {
    376392                    $a->addAttribute('rel', 'GACREL' . $this->currentGroup);
     393                }
     394            }
     395            else
     396            {
     397                if ($a['rel'])
     398                {
     399                    $a['rel'] = 'nofollow';
     400                }
     401                else
     402                {
     403                    $a->addAttribute('rel', 'nofollow');
    377404                }
    378405            }
     
    411438           return '<div ' . $id . ' class=' . $class . ' style=' . $style . '>' . $scontent . '<span class="wp-caption-text">' . $caption . '</span></div>';           
    412439        }
    413        
    414        
     440
    415441        // Complex group organization =
    416442        return <<<gacCode
  • gallery-and-caption/trunk/readme.txt

    r429775 r578236  
    55Tags: gallery,galleries,caption,captions,images,lightbox,colorbox,organization,dyerware
    66Requires at least: 2.8
    7 Tested up to: 3.2.1
    8 Stable tag: 1.2
     7Tested up to: 3.4.1
     8Stable tag: 1.3
    99
    1010Upgrades behavior of native galleries and captions in posts with dynamic animations and styling.  Captions can be grouped into 'mini' galleries.
     
    6969== Upgrade Notice ==
    7070
     71= 1.3 =
     72Fix for Wordpress 3.3+ editor buttons
     73Fix for Wordpress 3.4 captions not appearing or corrupted
     74Fix for Wordpress 3.3+ navigation buttons not appearing (wp 3.2 may lose them)
     75
    7176= 1.2 =
    7277Now supports multibyte languages in image file links
     
    95100
    96101== Changelog ==
     102
     103= 1.3 =
     104 * Fix for Wordpress 3.3+ editor buttons
     105 * Fix for Wordpress 3.4 captions not appearing or corrupted
     106 * Fix for Wordpress 3.3+ navigation buttons not appearing (wp 3.2 may lose them)
    97107
    98108= 1.2 =
Note: See TracChangeset for help on using the changeset viewer.