WordPress.org

Plugin Directory

Changeset 1697007


Ignore:
Timestamp:
07/16/17 13:22:28 (5 months ago)
Author:
likebtn
Message:

Update

Location:
likebtn-like-button/tags/2.3.4
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • likebtn-like-button/tags/2.3.4/includes/tab_votes.php

    r1621996 r1697007  
    171171 
    172172        <div class="tablenav"> 
     173 
    173174            <button type="button" class="button-secondary" onclick="likebtnVg('<?php _e('Votes Graph', LIKEBTN_I18N_DOMAIN); ?>', '<?php echo get_option('likebtn_plan') ?>')" ><img src="<?php echo _likebtn_get_public_url(); ?>img/graph.png" class="likebtn-btn-img"/> <?php _e('Votes Graph', LIKEBTN_I18N_DOMAIN); ?></button> 
     175 
     176            <button type="button" class="button-secondary" onclick="likebtnVotesExport('<?php _e('Export to CSV', LIKEBTN_I18N_DOMAIN); ?>')"><?php _e('Export to CSV', LIKEBTN_I18N_DOMAIN); ?></button> 
     177 
    174178        </div> 
    175179 
     
    611615    </script> 
    612616 
     617    <div id="likebtn_export" class="likebtn_export hidden"> 
     618        <form action="<?php echo admin_url('admin-ajax.php') ?>?action=likebtn_export_votes&<?php echo $_SERVER['QUERY_STRING'] ?>" method="post" target="_blank"> 
     619            <input type="hidden" name="export" value="1" /> 
     620            <strong><?php _e('Data to export', LIKEBTN_I18N_DOMAIN); ?>:</strong><br/> 
     621            <label><input type="checkbox" name="fields[]" value="user" checked="checked" /> <?php _e('User', LIKEBTN_I18N_DOMAIN); ?></label><br/> 
     622            <label><input type="checkbox" name="fields[]" value="ip" checked="checked" /> <?php _e('IP', LIKEBTN_I18N_DOMAIN); ?></label><br/> 
     623            <label><input type="checkbox" name="fields[]" value="country" checked="checked" /> <?php _e('Country', LIKEBTN_I18N_DOMAIN); ?></label><br/> 
     624            <label><input type="checkbox" name="fields[]" value="date" checked="checked" /> <?php _e('Date', LIKEBTN_I18N_DOMAIN); ?></label><br/> 
     625            <label><input type="checkbox" name="fields[]" value="type" checked="checked" /> <?php _e('Vote type', LIKEBTN_I18N_DOMAIN); ?></label><br/> 
     626            <label><input type="checkbox" name="fields[]" value="item" checked="checked" /> <?php _e('Item', LIKEBTN_I18N_DOMAIN); ?></label><br/><br/> 
     627            <strong><?php _e('Encoding', LIKEBTN_I18N_DOMAIN); ?>:</strong>  
     628            <select name="encoding"> 
     629                <option value="UCS-2LE">UTF-16LE (UCS-2LE) - <?php _e('Recommended'); ?></option> 
     630                <option value="UTF-8">UTF-8</option> 
     631                <option value="Windows-1251">ANSI (Windows-1251)</option> 
     632                <option value="Windows-1252">ANSI (Windows-1252)</option> 
     633            </select> 
     634            <br/><br/> 
     635            <strong><?php _e('Field Separator', LIKEBTN_I18N_DOMAIN); ?>:</strong>  
     636            <select name="separator"> 
     637                <option value="TAB">Tab (\t) - <?php _e('Recommended'); ?></option> 
     638                <option value=",">Comma (,)</option> 
     639                <option value=";">Semicolon (;)</option> 
     640                <option value="|">Pipe (|)</option> 
     641                <option value="&">Ampersand (&)</option> 
     642            </select> 
     643            <br/><br/> 
     644            <div class="ui-dialog-buttonpane ui-widget-content ui-helper-clearfix"> 
     645                <div class="ui-dialog-buttonset"> 
     646                    <button type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only button-primary likebtn-button-close" role="button"><span class="ui-button-text"><?php _e('Export', LIKEBTN_I18N_DOMAIN); ?></span></button> 
     647                    <button type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only button-secondary likebtn-button-close" role="button"><span class="ui-button-text"><?php _e('Close', LIKEBTN_I18N_DOMAIN); ?></span></button> 
     648                </div> 
     649            </div> 
     650        </form> 
     651    </div> 
     652 
    613653    <?php 
    614654 
  • likebtn-like-button/tags/2.3.4/languages/likebtn-like-button-ru_RU.po

    r1695793 r1697007  
    22msgstr "" 
    33"Project-Id-Version: LikeBtn Like Button\n" 
    4 "POT-Creation-Date: 2017-07-13 15:58+0545\n" 
    5 "PO-Revision-Date: 2017-07-13 16:03+0545\n" 
     4"POT-Creation-Date: 2017-07-14 10:16+0545\n" 
     5"PO-Revision-Date: 2017-07-14 10:16+0545\n" 
    66"Last-Translator: LikeBtn <support@likebtn.com>\n" 
    77"Language-Team: \n" 
     
    7474msgstr "Комментарий" 
    7575 
    76 #: ../likebtn_like_button.php:198 ../includes/tab_votes.php:185 
     76#: ../likebtn_like_button.php:198 ../likebtn_like_button.php:5485 
     77#: ../includes/tab_votes.php:189 ../includes/tab_votes.php:621 
    7778msgid "User" 
    7879msgstr "Пользователь" 
    7980 
    8081#: ../likebtn_like_button.php:199 ../likebtn_like_button.php:2941 
    81 #: ../includes/tab_votes.php:221 
     82#: ../likebtn_like_button.php:5526 ../includes/tab_votes.php:225 
    8283msgid "Custom Item" 
    8384msgstr "Произвольный элемент" 
     
    324325 
    325326#: ../likebtn_like_button.php:1884 ../likebtn_like_button.php:2064 
    326 #: ../includes/tab_votes.php:339 ../includes/tab_votes.php:414 
     327#: ../includes/tab_votes.php:343 ../includes/tab_votes.php:418 
    327328msgid "Error occured, please try again later." 
    328329msgstr "Произошла ошибка, пожалуйста, повторите попытку возже." 
     
    392393msgstr "Сортировка материалов по лайкам" 
    393394 
    394 #: ../likebtn_like_button.php:1927 ../includes/tab_votes.php:454 
     395#: ../likebtn_like_button.php:1927 ../includes/tab_votes.php:458 
    395396msgid "Votes graph" 
    396397msgstr "График голосов" 
     
    482483 
    483484#: ../likebtn_like_button.php:2623 ../likebtn_like_button.php:2722 
     485#: ../includes/tab_votes.php:176 
    484486msgid "Export to CSV" 
    485487msgstr "Экспорт в CSV" 
     
    517519 
    518520#: ../likebtn_like_button.php:2651 ../likebtn_like_button.php:2767 
    519 #: ../includes/tab_votes.php:142 ../includes/tab_votes.php:183 
     521#: ../includes/tab_votes.php:142 ../includes/tab_votes.php:187 
    520522msgid "Site" 
    521523msgstr "Сайт" 
     
    600602msgstr "Миниатюра" 
    601603 
    602 #: ../likebtn_like_button.php:2762 ../includes/tab_votes.php:189 
     604#: ../likebtn_like_button.php:2762 ../likebtn_like_button.php:5497 
     605#: ../includes/tab_votes.php:193 ../includes/tab_votes.php:625 
    603606msgid "Item" 
    604607msgstr "Элемент" 
     
    610613#: ../includes/meta_columns.php:73 ../includes/tab_settings.php:307 
    611614#: ../includes/tab_settings.php:319 ../includes/tab_votes.php:129 
    612 #: ../includes/tab_votes.php:468 
     615#: ../includes/tab_votes.php:472 
    613616msgid "Likes" 
    614617msgstr "Лайки" 
     
    620623#: ../includes/meta_columns.php:74 ../includes/tab_settings.php:308 
    621624#: ../includes/tab_settings.php:320 ../includes/tab_votes.php:130 
    622 #: ../includes/tab_votes.php:478 
     625#: ../includes/tab_votes.php:482 
    623626msgid "Dislikes" 
    624627msgstr "Дислайки" 
     
    661664msgstr "Смотреть голоса" 
    662665 
    663 #: ../likebtn_like_button.php:2877 
     666#: ../likebtn_like_button.php:2877 ../includes/tab_votes.php:620 
    664667msgid "Data to export" 
    665668msgstr "Данные для экспорта" 
     
    673676msgstr "IP-адреса проголосовавших" 
    674677 
    675 #: ../likebtn_like_button.php:2886 
     678#: ../likebtn_like_button.php:2886 ../includes/tab_votes.php:626 
    676679msgid "Encoding" 
    677680msgstr "Кодировка" 
    678681 
    679682#: ../likebtn_like_button.php:2888 ../likebtn_like_button.php:2896 
     683#: ../includes/tab_votes.php:628 ../includes/tab_votes.php:636 
    680684msgid "Recommended" 
    681685msgstr "Рекомендуется" 
    682686 
    683 #: ../likebtn_like_button.php:2894 
     687#: ../likebtn_like_button.php:2894 ../includes/tab_votes.php:634 
    684688msgid "Field Separator" 
    685689msgstr "Разделитель" 
    686690 
    687 #: ../likebtn_like_button.php:2905 
     691#: ../likebtn_like_button.php:2905 ../includes/tab_votes.php:645 
    688692msgid "Export" 
    689693msgstr "Экспорт" 
    690694 
    691695#: ../likebtn_like_button.php:2906 ../includes/tab_buttons.php:1391 
    692 #: ../includes/tab_votes.php:329 ../includes/tab_votes.php:343 
     696#: ../includes/tab_votes.php:333 ../includes/tab_votes.php:347 
     697#: ../includes/tab_votes.php:646 
    693698msgid "Close" 
    694699msgstr "Закрыть" 
    695700 
    696 #: ../likebtn_like_button.php:2978 ../likebtn_like_button.php:7754 
     701#: ../likebtn_like_button.php:2978 ../likebtn_like_button.php:7858 
    697702msgid "All Sites" 
    698703msgstr "Все сайты" 
     
    715720 
    716721#: ../likebtn_like_button.php:3252 ../likebtn_like_button.php:3291 
    717 #: ../includes/tab_votes.php:458 
     722#: ../includes/tab_votes.php:462 
    718723msgid "Total Votes" 
    719724msgstr "Всего голосов" 
    720725 
    721 #: ../likebtn_like_button.php:3259 ../includes/tab_votes.php:356 
     726#: ../likebtn_like_button.php:3259 ../includes/tab_votes.php:360 
    722727msgid "Loading..." 
    723728msgstr "Загрузка..." 
    724729 
    725 #: ../likebtn_like_button.php:3260 ../includes/tab_votes.php:357 
     730#: ../likebtn_like_button.php:3260 ../includes/tab_votes.php:361 
    726731msgid "Download JPEG image" 
    727732msgstr "Скачать как изображение JPEG" 
    728733 
    729 #: ../likebtn_like_button.php:3261 ../includes/tab_votes.php:358 
     734#: ../likebtn_like_button.php:3261 ../includes/tab_votes.php:362 
    730735msgid "Download PDF document" 
    731736msgstr "Скачать как документ PDF" 
    732737 
    733 #: ../likebtn_like_button.php:3262 ../includes/tab_votes.php:359 
     738#: ../likebtn_like_button.php:3262 ../includes/tab_votes.php:363 
    734739msgid "Download PNG image" 
    735740msgstr "Скачать как изображение PNG" 
    736741 
    737 #: ../likebtn_like_button.php:3263 ../includes/tab_votes.php:360 
     742#: ../likebtn_like_button.php:3263 ../includes/tab_votes.php:364 
    738743msgid "Download SVG vector image" 
    739744msgstr "Скачать как векторное изображение SVG" 
    740745 
    741 #: ../likebtn_like_button.php:3264 ../includes/tab_votes.php:361 
     746#: ../likebtn_like_button.php:3264 ../includes/tab_votes.php:365 
    742747msgid "Print chart" 
    743748msgstr "Печать" 
    744749 
    745 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     750#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    746751msgid "January" 
    747752msgstr "Январь" 
    748753 
    749 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     754#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    750755msgid "February" 
    751756msgstr "Февраль" 
    752757 
    753 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     758#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    754759msgid "March" 
    755760msgstr "Март" 
    756761 
    757 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     762#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    758763msgid "April" 
    759764msgstr "Апрель" 
    760765 
    761766#: ../likebtn_like_button.php:3265 ../likebtn_like_button.php:3267 
    762 #: ../includes/tab_votes.php:362 ../includes/tab_votes.php:364 
     767#: ../includes/tab_votes.php:366 ../includes/tab_votes.php:368 
    763768msgid "May" 
    764769msgstr "Май" 
    765770 
    766 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     771#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    767772msgid "June" 
    768773msgstr "Июнь" 
    769774 
    770 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     775#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    771776msgid "July" 
    772777msgstr "Июль" 
    773778 
    774 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     779#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    775780msgid "August" 
    776781msgstr "Август" 
    777782 
    778 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     783#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    779784msgid "September" 
    780785msgstr "Сентябрь" 
    781786 
    782 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     787#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    783788msgid "October" 
    784789msgstr "Октябрь" 
    785790 
    786 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     791#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    787792msgid "November" 
    788793msgstr "Ноябрь" 
    789794 
    790 #: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:362 
     795#: ../likebtn_like_button.php:3265 ../includes/tab_votes.php:366 
    791796msgid "December" 
    792797msgstr "Декабрь" 
    793798 
    794 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     799#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    795800msgid "Jan" 
    796801msgstr "Янв" 
    797802 
    798 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     803#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    799804msgid "Feb" 
    800805msgstr "Фев" 
    801806 
    802 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     807#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    803808msgid "Mar" 
    804809msgstr "Мар" 
    805810 
    806 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     811#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    807812msgid "Apr" 
    808813msgstr "Апр" 
    809814 
    810 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     815#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    811816msgid "Jun" 
    812817msgstr "Июн" 
    813818 
    814 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     819#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    815820msgid "Jul" 
    816821msgstr "Июл" 
    817822 
    818 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     823#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    819824msgid "Aug" 
    820825msgstr "Авг" 
    821826 
    822 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     827#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    823828msgid "Sep" 
    824829msgstr "Сен" 
    825830 
    826 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     831#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    827832msgid "Oct" 
    828833msgstr "Окт" 
    829834 
    830 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     835#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    831836msgid "Nov" 
    832837msgstr "Ноя" 
    833838 
    834 #: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:364 
     839#: ../likebtn_like_button.php:3267 ../includes/tab_votes.php:368 
    835840msgid "Dec" 
    836841msgstr "Дек" 
    837842 
    838 #: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:365 
     843#: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:369 
    839844msgid "Sunday" 
    840845msgstr "Воскресенье" 
    841846 
    842 #: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:365 
     847#: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:369 
    843848msgid "Monday" 
    844849msgstr "Понедельник" 
    845850 
    846 #: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:365 
     851#: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:369 
    847852msgid "Tuesday" 
    848853msgstr "Вторник" 
    849854 
    850 #: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:365 
     855#: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:369 
    851856msgid "Wednesday" 
    852857msgstr "Среда" 
    853858 
    854 #: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:365 
     859#: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:369 
    855860msgid "Thursday" 
    856861msgstr "Четверг" 
    857862 
    858 #: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:365 
     863#: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:369 
    859864msgid "Friday" 
    860865msgstr "Пятница" 
    861866 
    862 #: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:365 
     867#: ../likebtn_like_button.php:3268 ../includes/tab_votes.php:369 
    863868msgid "Saturday" 
    864869msgstr "Суббота" 
    865870 
    866 #: ../likebtn_like_button.php:3269 ../includes/tab_votes.php:366 
     871#: ../likebtn_like_button.php:3269 ../includes/tab_votes.php:370 
    867872msgid "No votes found" 
    868873msgstr "Голосов не найдено" 
     
    993998"- пожалуйста, обновитесь до ULTRA." 
    994999 
    995 #: ../likebtn_like_button.php:5654 
     1000#: ../likebtn_like_button.php:5488 ../includes/tab_votes.php:109 
     1001#: ../includes/tab_votes.php:622 
     1002msgid "IP" 
     1003msgstr "IP" 
     1004 
     1005#: ../likebtn_like_button.php:5491 ../includes/tab_buttons.php:1078 
     1006#: ../includes/tab_votes.php:191 ../includes/tab_votes.php:623 
     1007msgid "Date" 
     1008msgstr "Дата" 
     1009 
     1010#: ../likebtn_like_button.php:5494 ../includes/tab_votes.php:624 
     1011msgid "Vote type" 
     1012msgstr "Тип голоса" 
     1013 
     1014#: ../likebtn_like_button.php:5758 
    9961015msgid "Your website votes and stats have been reset." 
    9971016msgstr "Голоса и статистика вашего сайта были сброшены." 
    9981017 
    999 #: ../likebtn_like_button.php:5658 
     1018#: ../likebtn_like_button.php:5762 
    10001019msgid "" 
    10011020"Error occured resettings votes and stats. Make sure to enter valid account " 
     
    10051024"корректные данные аккаунта на вкладке Настройки." 
    10061025 
    1007 #: ../likebtn_like_button.php:5787 
     1026#: ../likebtn_like_button.php:5891 
    10081027msgid "List" 
    10091028msgstr "Список" 
    10101029 
    1011 #: ../likebtn_like_button.php:7196 
     1030#: ../likebtn_like_button.php:7300 
    10121031msgid "" 
    10131032"Congrats!</strong> Your website crossed the <strong>%votes% votes</strong> – " 
     
    10191038"%\" target=\"_blank\">здесь</a>." 
    10201039 
    1021 #: ../likebtn_like_button.php:7204 
     1040#: ../likebtn_like_button.php:7308 
    10221041msgid "Give 5 stars" 
    10231042msgstr "Оценить плагин в 5 звёзд" 
    10241043 
    1025 #: ../likebtn_like_button.php:7204 
     1044#: ../likebtn_like_button.php:7308 
    10261045msgid "Dismiss this notice" 
    10271046msgstr "Удалить уведомление" 
    10281047 
    1029 #: ../likebtn_like_button.php:7623 ../likebtn_like_button.php:7636 
     1048#: ../likebtn_like_button.php:7727 ../likebtn_like_button.php:7740 
    10301049msgid "" 
    10311050"Error occured importing Like button configuration: incorrect configuration " 
     
    10351054"конфигурации." 
    10361055 
    1037 #: ../likebtn_like_button.php:7654 
     1056#: ../likebtn_like_button.php:7758 
    10381057msgid "Like Button configuration has been successfully imported!" 
    10391058msgstr "Конфигурация кнопки Like была успешно импортирована!" 
    10401059 
    1041 #: ../likebtn_like_button.php:7658 
     1060#: ../likebtn_like_button.php:7762 
    10421061msgid "There were no any options imported." 
    10431062msgstr "Ни одной опции не импортировано." 
     
    17161735"гость голосует" 
    17171736 
    1718 #: ../includes/tab_buttons.php:807 ../includes/tab_votes.php:289 
     1737#: ../includes/tab_buttons.php:807 ../includes/tab_votes.php:293 
    17191738msgid "" 
    17201739"Make sure not to disable anonymous access to %admin_ajax%, otherwise votes " 
     
    20152034msgstr "" 
    20162035"Голосование активно в течение периода времени после публикации элемента" 
    2017  
    2018 #: ../includes/tab_buttons.php:1078 ../includes/tab_votes.php:187 
    2019 msgid "Date" 
    2020 msgstr "Дата" 
    20212036 
    20222037#: ../includes/tab_buttons.php:1080 
     
    27722787msgstr "ID пользователя" 
    27732788 
    2774 #: ../includes/tab_votes.php:109 
    2775 msgid "IP" 
    2776 msgstr "IP" 
    2777  
    2778 #: ../includes/tab_votes.php:115 ../includes/tab_votes.php:303 
     2789#: ../includes/tab_votes.php:115 ../includes/tab_votes.php:307 
    27792790msgid "Country" 
    27802791msgstr "Страна" 
     
    27922803msgstr "Найдено голосов" 
    27932804 
    2794 #: ../includes/tab_votes.php:173 
     2805#: ../includes/tab_votes.php:174 
    27952806msgid "Votes Graph" 
    27962807msgstr "График голосов" 
    27972808 
    2798 #: ../includes/tab_votes.php:188 
     2809#: ../includes/tab_votes.php:192 
    27992810msgid "Type" 
    28002811msgstr "Тип" 
    28012812 
    2802 #: ../includes/tab_votes.php:252 
     2813#: ../includes/tab_votes.php:256 
    28032814msgid "Anonymous" 
    28042815msgstr "Анонимный" 
    28052816 
    2806 #: ../includes/tab_votes.php:255 
     2817#: ../includes/tab_votes.php:259 
    28072818msgid "View IP info" 
    28082819msgstr "Смотреть информацию об IP" 
    28092820 
    2810 #: ../includes/tab_votes.php:284 
     2821#: ../includes/tab_votes.php:288 
    28112822msgid "Do not see votes?" 
    28122823msgstr "Нет голосов?" 
    28132824 
    2814 #: ../includes/tab_votes.php:287 
     2825#: ../includes/tab_votes.php:291 
    28152826msgid "" 
    28162827"If Like button is added using HTML-code votes will not be populated into " 
     
    28252836"[likebtn]</a>." 
    28262837 
    2827 #: ../includes/tab_votes.php:307 
     2838#: ../includes/tab_votes.php:311 
    28282839msgid "City" 
    28292840msgstr "Город" 
    28302841 
    2831 #: ../includes/tab_votes.php:311 
     2842#: ../includes/tab_votes.php:315 
    28322843msgid "Lat/Long" 
    28332844msgstr "Шир/долг" 
    28342845 
    2835 #: ../includes/tab_votes.php:315 
     2846#: ../includes/tab_votes.php:319 
    28362847msgid "Postal Code" 
    28372848msgstr "Почтовый код" 
    28382849 
    2839 #: ../includes/tab_votes.php:319 
     2850#: ../includes/tab_votes.php:323 
    28402851msgid "Network" 
    28412852msgstr "Сеть" 
    28422853 
    2843 #: ../includes/tab_votes.php:323 
     2854#: ../includes/tab_votes.php:327 
    28442855msgid "Hostname" 
    28452856msgstr "Имя хоста" 
    28462857 
    2847 #: ../includes/tab_votes.php:406 
     2858#: ../includes/tab_votes.php:410 
    28482859msgid "Please upgrade at least to %plan% in order to user this feature." 
    28492860msgstr "" 
     
    28512862"функцией." 
    28522863 
    2853 #: ../includes/tab_votes.php:509 
     2864#: ../includes/tab_votes.php:513 
    28542865msgid "Back" 
    28552866msgstr "Назад" 
    28562867 
    2857 #: ../includes/tab_votes.php:518 ../includes/tab_votes.php:577 
     2868#: ../includes/tab_votes.php:522 ../includes/tab_votes.php:581 
    28582869msgid "Click to view details" 
    28592870msgstr "Кликните, чтобы просмотреть" 
  • likebtn-like-button/tags/2.3.4/likebtn_like_button.class.php

    r1695793 r1697007  
    388388                    // check if post exists and is not revision 
    389389                    if (!empty($post) && !empty($post->post_type) && $post->post_type != 'revision') { 
    390                         if ($likes != -1) { 
    391                             if (count(get_post_meta($entity_id, LIKEBTN_META_KEY_LIKES)) > 1) { 
    392                                 delete_post_meta($entity_id, LIKEBTN_META_KEY_LIKES); 
    393                                 add_post_meta($entity_id, LIKEBTN_META_KEY_LIKES, $likes, true); 
    394                             } else { 
    395                                 update_post_meta($entity_id, LIKEBTN_META_KEY_LIKES, $likes); 
     390                         
     391                        likebtn_set_post_votes($entity_id, $likes, $dislikes, $likes_minus_dislikes); 
     392 
     393                        // WPML 
     394                        if (($entity_name == LIKEBTN_ENTITY_POST || $entity_name == LIKEBTN_ENTITY_PAGE) && liebtn_is_wpml_active()) { 
     395                            global $sitepress; 
     396                            $trid = $sitepress->get_element_trid($entity_id, 'post_'.$entity_name); 
     397                            //$translations = $sitepress->get_element_translations($trid,'post_'.$entity_name); 
     398                            $translations = $wpdb->get_results(" 
     399                                SELECT element_id 
     400                                FROM {$wpdb->prefix}icl_translations 
     401                                WHERE trid = {$trid}  
     402                                AND element_type = 'post_{$entity_name}'  
     403                            "); 
     404                            foreach ($translations as $langkey => $translation) { 
     405                                likebtn_set_post_votes($translation->element_id, $likes, $dislikes, $likes_minus_dislikes); 
    396406                            } 
    397407                        } 
    398                         if ($dislikes != -1) { 
    399                             if (count(get_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES)) > 1) { 
    400                                 delete_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES); 
    401                                 add_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES, $dislikes, true); 
    402                             } else { 
    403                                 update_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES, $dislikes); 
    404                             } 
    405                         } 
    406                         if ($likes_minus_dislikes !== null) { 
    407                             if (count(get_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES)) > 1) { 
    408                                 delete_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES); 
    409                                 add_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES, $likes_minus_dislikes, true); 
    410                             } else { 
    411                                 update_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES, $likes_minus_dislikes); 
    412                             } 
    413                         } 
     408 
    414409                        $entity_updated = true; 
    415410                    } 
  • likebtn-like-button/tags/2.3.4/likebtn_like_button.php

    r1695793 r1697007  
    37963796add_shortcode('likebtn_liked_by_user', 'likebtn_liked_by_user_widget_shortcode'); 
    37973797 
     3798// number of votes of the user 
     3799function likebtn_user_votes_shortcode($args) { 
     3800 
     3801    global $wpdb; 
     3802 
     3803    if (!empty($args['user_id'])) { 
     3804        $user_id = $args['user_id']; 
     3805    } else { 
     3806        $user_id = get_current_user_id(); 
     3807    } 
     3808 
     3809    if (!empty($args['type'])) { 
     3810        if ($args['type'] == 'dislikes') { 
     3811            $type = LIKEBTN_VOTE_DISLIKE; 
     3812        } elseif ($args['type'] == 'total') { 
     3813            $type = ''; 
     3814        } else { 
     3815            $type = LIKEBTN_VOTE_LIKE; 
     3816        } 
     3817    } else { 
     3818        $type = LIKEBTN_VOTE_LIKE; 
     3819    } 
     3820 
     3821    $query_parameters = array( 
     3822        'user_id' => $user_id, 
     3823        'type'    => $type, 
     3824    ); 
     3825    $query = " 
     3826        SELECT count(*) 
     3827        FROM ".$wpdb->prefix . LIKEBTN_TABLE_VOTE." 
     3828        WHERE user_id = %d 
     3829    "; 
     3830 
     3831    if ($type) { 
     3832        $query .= " AND type = %d "; 
     3833    } 
     3834 
     3835    $query_prepared = $wpdb->prepare($query, $query_parameters); 
     3836    $votes_count = (int)$wpdb->get_var($query_prepared); 
     3837 
     3838    return $votes_count; 
     3839} 
     3840 
     3841add_shortcode('likebtn_user_votes', 'likebtn_user_votes_shortcode'); 
     3842 
    37983843// Likes shortcode 
    37993844function likebtn_shortcode_likes($args) { 
     
    50325077    $index = 1; 
    50335078    foreach ($likebtn_system_check as $addr) { 
    5034         $addr_result = json_decode($likebtn->curl($addr), true); 
    5035  
    5036         if (is_array($addr_result) && $addr_result['result'] == 'error' && !isset($addr_result['response'])) { 
    5037             $response['result'] = 'error'; 
    5038             $response['result_text'] .= ' '.$index.') '.strtr( 
    5039                 __('%addr% is not available from your server', LIKEBTN_I18N_DOMAIN),  
    5040                 array( 
    5041                     '%addr%' => $addr 
    5042                 ) 
    5043             ); 
    5044             if ($addr_result['message']) { 
    5045                 $response['result_text'] .= ': '.$addr_result['message']; 
     5079        $add_response = $likebtn->curl($addr); 
     5080        $addr_result = json_decode($add_response, true); 
     5081 
     5082        if (is_array($addr_result)) { 
     5083            if ($addr_result['result'] == 'error' && !isset($addr_result['response'])) { 
     5084                $response['result'] = 'error'; 
     5085                $response['result_text'] .= ' '.$index.') '.strtr( 
     5086                    __('%addr% is not available from your server', LIKEBTN_I18N_DOMAIN),  
     5087                    array( 
     5088                        '%addr%' => $addr 
     5089                    ) 
     5090                ); 
     5091                if ($addr_result['message']) { 
     5092                    $response['result_text'] .= ': '.$addr_result['message']; 
     5093                } 
     5094                //$response['result_text'] .= "<br/>"; 
     5095                $index++; 
    50465096            } 
    5047             //$response['result_text'] .= "<br/>"; 
    5048             $index++; 
     5097        } else { 
     5098            // Proxy error for example 
     5099            if (is_string($add_response) && strstr($add_response, '<html>')) { 
     5100                $response['result_html'] = $add_response; 
     5101                $response['result'] = 'error'; 
     5102                $response['result_text'] .= ' '.$index.') '.strtr( 
     5103                    __('%addr% is not available from your server', LIKEBTN_I18N_DOMAIN),  
     5104                    array( 
     5105                        '%addr%' => $addr 
     5106                    ) 
     5107                ); 
     5108            } 
    50495109        } 
    50505110    } 
     
    54415501 
    54425502add_action('wp_ajax_likebtn_export', 'likebtn_export_callback'); 
     5503 
     5504// Export statistics 
     5505function likebtn_export_votes_callback() { 
     5506     
     5507    global $wpdb; 
     5508 
     5509    list($query_prepared, $blogs, $votes_blog_id, $entity_name, $post_id, $user_id, $ip, $vote_type, $country) = likebtn_votes_query(); 
     5510    $votes = $wpdb->get_results($query_prepared); 
     5511 
     5512    $post_fields = $_POST['fields']; 
     5513    $fields = array(); 
     5514 
     5515    foreach ($post_fields as $key => $value) { 
     5516        switch ($value) { 
     5517            case 'user': 
     5518                $fields[] = __('User', LIKEBTN_I18N_DOMAIN); 
     5519                break; 
     5520            case 'ip': 
     5521                $fields[] = __('IP', LIKEBTN_I18N_DOMAIN); 
     5522                break; 
     5523            case 'country': 
     5524                $fields[] = __('Country', LIKEBTN_I18N_DOMAIN); 
     5525                break; 
     5526            case 'date': 
     5527                $fields[] = __('Date', LIKEBTN_I18N_DOMAIN); 
     5528                break; 
     5529            case 'type': 
     5530                $fields[] = __('Vote type', LIKEBTN_I18N_DOMAIN); 
     5531                break; 
     5532            case 'item': 
     5533                $fields[] = __('Item', LIKEBTN_I18N_DOMAIN); 
     5534                break; 
     5535        } 
     5536    } 
     5537 
     5538    $results = array(); 
     5539    foreach ($votes as $value) { 
     5540        $new_row = array(); 
     5541        if (in_array('user', $post_fields)) { 
     5542            $new_row[] = _likebtn_get_entity_title(LIKEBTN_ENTITY_USER, $value->user_id); 
     5543        } 
     5544        if (in_array('ip', $post_fields)) { 
     5545            $new_row[] = $value->ip; 
     5546        } 
     5547        if (in_array('country', $post_fields)) { 
     5548            $new_row[] = $value->country; 
     5549        } 
     5550        if (in_array('date', $post_fields)) { 
     5551            $new_row[] = date("Y.m.d H:i:s", strtotime($value->created_at)); 
     5552        } 
     5553        if (in_array('type', $post_fields)) { 
     5554            if ((int)$value->type == 1) { 
     5555                $entity_vote_type = 'like'; 
     5556            } else { 
     5557                $entity_vote_type = 'dislike'; 
     5558            } 
     5559            $new_row[] = $entity_vote_type; 
     5560        } 
     5561        if (in_array('item', $post_fields)) { 
     5562            if ($value->item_id) { 
     5563                $item_title = $value->identifier; 
     5564                //$item_url = $votes_item->url; 
     5565                $entity_type_name = __('Custom Item', LIKEBTN_I18N_DOMAIN); 
     5566            } else { 
     5567                $entity_info = _likebtn_parse_identifier($value->identifier); 
     5568                if ($entity_info['entity_name'] && $entity_info['entity_id']) { 
     5569                    $item_title = _likebtn_get_entity_title($entity_info['entity_name'], $entity_info['entity_id']); 
     5570                    $item_title = _likebtn_prepare_title($entity_info['entity_name'], $item_title); 
     5571                    //$item_url = _likebtn_get_entity_url($entity_info['entity_name'], $entity_info['entity_id'], '', $votes_blog_id); 
     5572                } 
     5573                $entity_type_name = _likebtn_get_entity_name_title($entity_info['entity_name']); 
     5574            } 
     5575 
     5576            $new_row[] = $item_title . ' — '.$entity_type_name; 
     5577        } 
     5578        $results[] = $new_row; 
     5579    } 
     5580 
     5581    $filename = 'likebtn_votes_'.date('Y-m-d').'.csv'; 
     5582    likebtn_to_csv($results, $filename, $fields, $_POST['encoding'], $_POST['separator']); 
     5583} 
     5584 
     5585add_action('wp_ajax_likebtn_export_votes', 'likebtn_export_votes_callback'); 
    54435586 
    54445587function likebtn_vgaph_callback() { 
     
    78618004        $prefix = "{$prefix_prepared}{$votes_blog_id}_"; 
    78628005        if (!$query_select) { 
    7863             $query_select = ' SQL_CALC_FOUND_ROWS v.id, v.identifier, v.type, v.user_id, v.ip, v.created_at, i.ID as item_id, i.url '; 
     8006            $query_select = ' SQL_CALC_FOUND_ROWS v.id, v.identifier, v.type, v.user_id, v.ip, v.created_at, v.country, i.ID as item_id, i.url '; 
    78648007        } 
    78658008        $query = _likebtn_get_votes_sql($prefix, $query_where, $query_orderby, $query_limit, $query_select, $query_join); 
     
    78738016            } 
    78748017            if (!$query_select) { 
    7875                 $blog_query_select = $blog->blog_id . ' as blog_id, v.id, v.identifier, v.type, v.user_id, v.ip, v.created_at, i.ID as item_id, i.url '; 
     8018                $blog_query_select = $blog->blog_id . ' as blog_id, v.id, v.identifier, v.type, v.user_id, v.ip, v.created_at, v.country, i.ID as item_id, i.url '; 
    78768019            } else { 
    78778020                $blog_query_select = $query_select; 
     
    78828025    } else { 
    78838026        if (!$query_select) { 
    7884             $query_select = ' SQL_CALC_FOUND_ROWS v.id, v.identifier, v.type, v.user_id, v.ip, v.created_at, i.ID as item_id, i.url '; 
     8027            $query_select = ' SQL_CALC_FOUND_ROWS v.id, v.identifier, v.type, v.user_id, v.ip, v.created_at, v.country, i.ID as item_id, i.url '; 
    78858028        } 
    78868029        $query = _likebtn_get_votes_sql($prefix_prepared, $query_where, $query_orderby, $query_limit, $query_select, $query_join); 
     
    79278070function likebtn_get_the_ID() 
    79288071{ 
    7929     if (class_exists('SitePress')) { 
     8072    if (likebtn_is_wpml_active()) { 
    79308073        // WPML is active 
    79318074        global $sitepress; 
     
    79378080} 
    79388081 
     8082// Is WPML active 
     8083function likebtn_is_wpml_active() 
     8084{ 
     8085    if (class_exists('SitePress')) { 
     8086        return true; 
     8087    } else { 
     8088        return false; 
     8089    } 
     8090} 
     8091 
     8092// Set votes for a post 
     8093function likebtn_set_post_votes($entity_id, $likes, $dislikes, $likes_minus_dislikes) 
     8094{ 
     8095    if ($likes != -1) { 
     8096        if (count(get_post_meta($entity_id, LIKEBTN_META_KEY_LIKES)) > 1) { 
     8097            delete_post_meta($entity_id, LIKEBTN_META_KEY_LIKES); 
     8098            add_post_meta($entity_id, LIKEBTN_META_KEY_LIKES, $likes, true); 
     8099        } else { 
     8100            update_post_meta($entity_id, LIKEBTN_META_KEY_LIKES, $likes); 
     8101        } 
     8102    } 
     8103    if ($dislikes != -1) { 
     8104        if (count(get_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES)) > 1) { 
     8105            delete_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES); 
     8106            add_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES, $dislikes, true); 
     8107        } else { 
     8108            update_post_meta($entity_id, LIKEBTN_META_KEY_DISLIKES, $dislikes); 
     8109        } 
     8110    } 
     8111    if ($likes_minus_dislikes !== null) { 
     8112        if (count(get_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES)) > 1) { 
     8113            delete_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES); 
     8114            add_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES, $likes_minus_dislikes, true); 
     8115        } else { 
     8116            update_post_meta($entity_id, LIKEBTN_META_KEY_LIKES_MINUS_DISLIKES, $likes_minus_dislikes); 
     8117        } 
     8118    } 
     8119} 
     8120 
    79398121/** 
    79408122 * Buttons tab 
  • likebtn-like-button/tags/2.3.4/public/js/admin.js

    r1621996 r1697007  
    446446            } else { 
    447447                jQuery(".likebtn_sc_container:first").css('color', 'green'); 
     448            } 
     449 
     450            if (typeof(response.result_html) != "undefined") { 
     451                var sc_win = likebtnPopup("", result_text); 
     452                sc_win.document.body.innerHTML = response.result_html; 
    448453            } 
    449454        }, 
     
    12501255        return false; 
    12511256    } 
     1257} 
     1258 
     1259// Export votes 
     1260function likebtnVotesExport(msg_export) 
     1261{ 
     1262    var likebtn_export = jQuery("#likebtn_export").clone(); 
     1263    likebtn_export.removeClass('hidden'); 
     1264    likebtn_export.removeAttr('id'); 
     1265 
     1266    likebtn_export.dialog({ 
     1267        resizable: false, 
     1268        autoOpen: false, 
     1269        modal: true, 
     1270        width: 430, 
     1271        title: msg_export, 
     1272        draggable: false, 
     1273        show: 'fade', 
     1274        dialogClass: 'likebtn_dlg', 
     1275        open: function() { 
     1276            jQuery('.ui-widget-overlay, .likebtn_export .likebtn-button-close').bind('click', function() { 
     1277                likebtn_export.dialog('close'); 
     1278            }); 
     1279        }, 
     1280        position: {  
     1281            my: "center",  
     1282            at: "center"  
     1283        } 
     1284    }); 
     1285 
     1286    likebtn_export.dialog('open'); 
    12521287} 
    12531288 
Note: See TracChangeset for help on using the changeset viewer.