Plugin Directory

Changeset 580792


Ignore:
Timestamp:
08/02/2012 01:30:34 PM (14 years ago)
Author:
spectraweb
Message:
 
Location:
wp-auto-columns/trunk
Files:
1 added
5 edited
1 copied

Legend:

Unmodified
Added
Removed
  • wp-auto-columns/trunk/languages/wp-auto-columns-en_US.po

    r561575 r580792  
    33"Project-Id-Version: WP Auto Colums\n"
    44"Report-Msgid-Bugs-To: \n"
    5 "POT-Creation-Date: 2012-06-20 15:56+0300\n"
    6 "PO-Revision-Date: 2012-06-20 15:57+0300\n"
     5"POT-Creation-Date: 2012-08-02 17:27+0400\n"
     6"PO-Revision-Date: 2012-08-02 17:28+0400\n"
    77"Last-Translator: Andrey Ovcharov <andrew.ovcharov@gmail.com>\n"
    88"Language-Team: Spectraweb s.r.o. <info@spectraweb.cz>\n"
     9"Language: en_US\n"
    910"MIME-Version: 1.0\n"
    1011"Content-Type: text/plain; charset=UTF-8\n"
     
    1213"X-Poedit-KeywordsList: _;gettext;gettext_noop;__;_e;_x\n"
    1314"X-Poedit-Basepath: .\n"
    14 "X-Poedit-Language: Russian\n"
    15 "X-Poedit-Country: RUSSIAN FEDERATION\n"
    16 "X-Poedit-SourceCharset: utf-8\n"
     15"X-Poedit-SourceCharset: UTF-8\n"
    1716"X-Poedit-SearchPath-0: ..\n"
    1817
    1918#: ../wp-auto-columns.php:32
    20 msgid "This plugin requires DOM API (<a href=\"http://www.php.net/manual/en/dom.setup.php\" target=\"_blank\">more info</a>)"
    21 msgstr "Плагин требует установки DOM API (<a href=\"http://www.php.net/manual/ru/dom.setup.php\" target=\"_blank\">подробнее</a>)"
     19msgid ""
     20"This plugin requires Tidy (<a href=\"http://www.php.net/manual/en/book.tidy."
     21"php\" target=\"_blank\">more info</a>)"
     22msgstr ""
    2223
     24#: ../wp-auto-columns.php:37
     25msgid ""
     26"This plugin requires DOM API (<a href=\"http://www.php.net/manual/en/book."
     27"dom.php\" target=\"_blank\">more info</a>)"
     28msgstr ""
     29
     30#: ../wp-auto-columns.php:97
     31msgid "Auto Columns Options"
     32msgstr ""
     33
     34#: ../wp-auto-columns.php:97
     35msgid "Auto Columns"
     36msgstr ""
     37
     38#: ../templates/settings.phtml:2
     39msgid "Auto Columns Settings"
     40msgstr ""
     41
     42#: ../templates/settings.phtml:14
     43msgid "Default split style"
     44msgstr ""
     45
     46#: ../templates/settings.phtml:19
     47msgid "Div"
     48msgstr ""
     49
     50#: ../templates/settings.phtml:20
     51msgid "Table"
     52msgstr ""
     53
     54#: ../templates/settings.phtml:32
     55msgid "Line height in pixels"
     56msgstr ""
     57
     58#: ../templates/settings.phtml:41
     59msgid "Header tags"
     60msgstr ""
     61
     62#: ../templates/settings.phtml:46
     63msgid "Comma separated list of header tags"
     64msgstr ""
     65
     66#: ../templates/settings.phtml:51
     67msgid "Splittable tags"
     68msgstr ""
     69
     70#: ../templates/settings.phtml:56
     71msgid "Comma separated list of tags allowed to split between columns"
     72msgstr ""
     73
     74#: ../templates/settings.phtml:64
     75msgid "Splitter fine tuning"
     76msgstr ""
     77
     78#: ../templates/settings.phtml:70
     79msgid "Chars in line"
     80msgstr ""
     81
     82#: ../templates/settings.phtml:71
     83msgid "line-height"
     84msgstr ""
     85
     86#: ../templates/settings.phtml:72
     87msgid "margin-bottom"
     88msgstr ""
     89
     90#: ../templates/settings.phtml:119
     91msgid "These settings are for real experts. Use on your own risk"
     92msgstr ""
     93
     94#: ../templates/settings.phtml:126
     95msgid "Save Changes"
     96msgstr ""
  • wp-auto-columns/trunk/languages/wp-auto-columns-ru_RU.po

    r561063 r580792  
    33"Project-Id-Version: WP Auto Colums\n"
    44"Report-Msgid-Bugs-To: \n"
    5 "POT-Creation-Date: 2012-06-20 15:56+0300\n"
    6 "PO-Revision-Date: 2012-06-20 15:57+0300\n"
     5"POT-Creation-Date: 2012-08-02 17:24+0300\n"
     6"PO-Revision-Date: 2012-08-02 17:26+0300\n"
    77"Last-Translator: Andrey Ovcharov <andrew.ovcharov@gmail.com>\n"
    88"Language-Team: Spectraweb s.r.o. <info@spectraweb.cz>\n"
     
    1818
    1919#: ../wp-auto-columns.php:32
    20 msgid "This plugin requires DOM API (<a href=\"http://www.php.net/manual/en/dom.setup.php\" target=\"_blank\">more info</a>)"
     20msgid "This plugin requires Tidy (<a href=\"http://www.php.net/manual/en/book.tidy.php\" target=\"_blank\">more info</a>)"
    2121msgstr "Плагин требует установки DOM API (<a href=\"http://www.php.net/manual/ru/dom.setup.php\" target=\"_blank\">подробнее</a>)"
    2222
     23#: ../wp-auto-columns.php:37
     24msgid "This plugin requires DOM API (<a href=\"http://www.php.net/manual/en/book.dom.php\" target=\"_blank\">more info</a>)"
     25msgstr "Плагин требует установки DOM API (<a href=\"http://www.php.net/manual/ru/dom.setup.php\" target=\"_blank\">подробнее</a>)"
     26
     27#: ../wp-auto-columns.php:97
     28msgid "Auto Columns Options"
     29msgstr "Настройки Auto Columns"
     30
     31#: ../wp-auto-columns.php:97
     32msgid "Auto Columns"
     33msgstr "Auto Columns"
     34
     35#: ../templates/settings.phtml:2
     36msgid "Auto Columns Settings"
     37msgstr "Настройки Auto Columns"
     38
     39#: ../templates/settings.phtml:14
     40msgid "Default split style"
     41msgstr "Способ разбивки по умолчанию"
     42
     43#: ../templates/settings.phtml:19
     44msgid "Div"
     45msgstr "Div"
     46
     47#: ../templates/settings.phtml:20
     48msgid "Table"
     49msgstr "Таблица"
     50
     51#: ../templates/settings.phtml:32
     52msgid "Line height in pixels"
     53msgstr "Высота строки в пикселях"
     54
     55#: ../templates/settings.phtml:41
     56msgid "Header tags"
     57msgstr "Тэги заголовков"
     58
     59#: ../templates/settings.phtml:46
     60msgid "Comma separated list of header tags"
     61msgstr "Список тэгов, используемых в качестве заголовков"
     62
     63#: ../templates/settings.phtml:51
     64msgid "Splittable tags"
     65msgstr ""
     66
     67#: ../templates/settings.phtml:56
     68msgid "Comma separated list of tags allowed to split between columns"
     69msgstr "Список тэгов, которые можно разносить по разным колонкам"
     70
     71#: ../templates/settings.phtml:64
     72msgid "Splitter fine tuning"
     73msgstr "Тонкие настройки разбивщика"
     74
     75#: ../templates/settings.phtml:70
     76msgid "Chars in line"
     77msgstr "Символов в строке"
     78
     79#: ../templates/settings.phtml:71
     80msgid "line-height"
     81msgstr ""
     82
     83#: ../templates/settings.phtml:72
     84msgid "margin-bottom"
     85msgstr ""
     86
     87#: ../templates/settings.phtml:119
     88msgid "These settings are for real experts. Use on your own risk"
     89msgstr "Эти настройки требуют опыта. Используйте их на свой риск."
     90
     91#: ../templates/settings.phtml:126
     92msgid "Save Changes"
     93msgstr "Сохранить изменения"
     94
  • wp-auto-columns/trunk/readme.txt

    r564020 r580792  
    55Requires at least: 3.1.0
    66Tested up to: 3.3.1
    7 Stable tag: 1.0.5
     7Stable tag: 1.0.6
    88
    99Wrap block of text with shortcode. It will be split into columns. Automagically.
     
    1111== Description ==
    1212
    13 I needed automated, tag-aware column splitter for one of my projects. So I have created one.
     13You need to display your articles in magazine or newspaper style. Use this plugin. You don't have
     14to change your theme files or add styles - just use "table" splitter.
    1415
    1516= Features =
    1617
    1718*   fully automatic splitter;
     19*   create columns in table or div's;
    1820*   tag-aware;
    1921*   splits long paragraphs and unordered lists;
     
    5860== Changelog ==
    5961
     62= 1.0.6 =
     63* Added parameter `style="table|div"` to define desired split style.
     64
    6065= 1.0.5 =
    6166* Added processing of "height" attribute for IMG tags
  • wp-auto-columns/trunk/templates/settings.phtml

    r564020 r580792  
    1111        <?php settings_fields('wp_auto_columns'); ?>
    1212        <table class="form-table">
     13            <tr valign="top">
     14                <th scope="row"><?php _e('Default split style', 'wp-auto-columns') ?></th>
     15                <td>
     16                    <?php
     17                    $split_style = get_option('wp_auto_columns_split_style', 'div');
     18                    $styles = array(
     19                        'div' => __('Div', 'wp-auto-columns'),
     20                        'table' => __('Table', 'wp-auto-columns'),
     21                    );
     22                    ?>
     23                    <select name="wp_auto_columns_split_style">
     24                        <?php foreach ($styles as $id => $name) : ?>
     25                            <option value="<?php echo $id ?>" <?php if ($id == $split_style) echo 'selected="selected"' ?>><?php echo $name ?></option>
     26                        <?php endforeach; ?>
     27                    </select>
     28                </td>
     29            </tr>
     30
    1331            <tr valign="top">
    1432                <th scope="row"><?php _e('Line height in pixels', 'wp-auto-columns') ?></th>
  • wp-auto-columns/trunk/wp-auto-columns.php

    r564020 r580792  
    77  Author: Spectraweb s.r.o.
    88  Author URI: http://www.spectraweb.cz
    9   Version: 1.0.5
     9  Version: 1.0.6
    1010 */
    1111
     
    7272
    7373            add_shortcode('auto_columns', array('WPAutoColumns', 'shortcode'));
     74            add_shortcode('auto-columns', array('WPAutoColumns', 'shortcode'));
    7475        }
    7576    }
     
    8081    public static function on_admin_init()
    8182    {
     83        register_setting('wp_auto_columns', 'wp_auto_columns_split_style');
    8284        register_setting('wp_auto_columns', 'wp_auto_columns_line_height');
    8385
     
    103105    public static function shortcode($atts, $content = '')
    104106    {
    105         extract(shortcode_atts(array('columns' => 2), $atts));
     107        extract(shortcode_atts(array('columns' => 2, 'style' => ''), $atts));
    106108
    107109        $config = array(
     
    124126        }
    125127
     128        if ($style == '')
     129        {
     130            $style = get_option('wp_auto_columns_split_style', 'div');
     131        }
     132
     133
    126134        // construct container
    127135        $class = array('auto-columns-container', 'columns-' . $columns);
    128         $ret = '<div class="' . implode(' ', $class) . '">';
     136
     137        $ret = '';
     138
     139        if ($style == 'div')
     140        {
     141            $ret .= '<div class="' . implode(' ', $class) . '">';
     142        }
     143        else if ($style == 'table')
     144        {
     145            $ret .= '<table class="' . implode(' ', $class) . '"><tbody><tr>';
     146        }
    129147
    130148        for ($i = 0; $i < count($col_array); $i++)
     
    140158                $class[] = 'last-column';
    141159            }
     160
    142161            // add column
    143             $ret .= '<div class="' . implode(' ', $class) . '">';
     162            if ($style == 'div')
     163            {
     164                $ret .= '<div class="' . implode(' ', $class) . '">';
     165            }
     166            else if ($style == 'table')
     167            {
     168                $ret .= '<td class="' . implode(' ', $class) . '">';
     169            }
     170
     171            //
    144172            foreach ($col_array[$i] as $tag)
    145173            {
    146174                $ret .= $tag;
    147175            }
     176
     177            if ($style == 'div')
     178            {
     179                $ret .= '</div>';
     180            }
     181            else if ($style == 'table')
     182            {
     183                $ret .= '</td>';
     184            }
     185        }
     186
     187        if ($style == 'div')
     188        {
     189            $ret .= '<div class="auto-columns-clear"></div>';
    148190            $ret .= '</div>';
    149191        }
    150 
    151         $ret .= '<div class="auto-columns-clear"></div>';
    152         $ret .= '</div>';
     192        else if ($style == 'table')
     193        {
     194            $ret .= '</tr></tbody></table>';
     195        }
     196
     197
    153198
    154199        return $ret;
Note: See TracChangeset for help on using the changeset viewer.