Plugin Directory

Changeset 2207376


Ignore:
Timestamp:
12/06/2019 07:38:18 PM (6 years ago)
Author:
kerkenit
Message:

Release 1.2.5

Location:
promissa/trunk
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • promissa/trunk/languages/promissa-nl_NL.po

    r2188093 r2207376  
    22msgstr ""
    33"Project-Id-Version: Pro Missa\n"
    4 "POT-Creation-Date: 2019-11-08 00:04+0100\n"
    5 "PO-Revision-Date: 2019-11-08 00:04+0100\n"
     4"POT-Creation-Date: 2019-12-06 19:22+0100\n"
     5"PO-Revision-Date: 2019-12-06 19:22+0100\n"
    66"Last-Translator: Kerk en IT <info@kerkenit.nl>\n"
    77"Language-Team: Marco van 't Klooster <info@kerkenit.nl>\n"
     
    105105msgstr "zondags"
    106106
    107 #. Plugin Name of the plugin/theme
    108 #: promissa.php:97 promissa.php:98
     107#: promissa.php:86 promissa.php:87
    109108msgid "Pro Missa"
    110109msgstr "Pro Missa"
     
    198197msgstr "Toon aanwezigen:"
    199198
    200 #. Plugin URI of the plugin/theme
    201 msgid "https://www.promissa.nl/plugins/wordpress"
    202 msgstr "https://www.promissa.nl/plugins/wordpress"
    203 
    204 #. Description of the plugin/theme
    205 msgid ""
    206 "This plugin will give you shortcodes and widgets with the latest masses and "
    207 "events of Pro Missa."
    208 msgstr ""
    209 "Deze plug-in geeft je shortcodes en widgets met de nieuwste missen en "
    210 "evenementen van Pro Missa."
    211 
    212 #. Author of the plugin/theme
    213 msgid "Kerk en IT"
    214 msgstr "Kerk en IT"
    215 
    216 #. Author URI of the plugin/theme
    217 msgid "https://www.kerkenit.nl"
    218 msgstr "https://www.kerkenit.nl"
     199#~ msgid "https://www.promissa.nl/plugins/wordpress"
     200#~ msgstr "https://www.promissa.nl/plugins/wordpress"
     201
     202#~ msgid ""
     203#~ "This plugin will give you shortcodes and widgets with the latest masses "
     204#~ "and events of Pro Missa."
     205#~ msgstr ""
     206#~ "Deze plug-in geeft je shortcodes en widgets met de nieuwste missen en "
     207#~ "evenementen van Pro Missa."
     208
     209#~ msgid "Kerk en IT"
     210#~ msgstr "Kerk en IT"
     211
     212#~ msgid "https://www.kerkenit.nl"
     213#~ msgstr "https://www.kerkenit.nl"
    219214
    220215#~ msgid "Every"
  • promissa/trunk/languages/promissa.pot

    r2188093 r2207376  
    44"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
    55"Project-Id-Version: Pro Missa\n"
    6 "POT-Creation-Date: 2019-11-08 00:03+0100\n"
     6"POT-Creation-Date: 2019-12-06 19:22+0100\n"
    77"PO-Revision-Date: 2019-07-29 16:31+0200\n"
    88"Last-Translator: Kerk en IT <info@kerkenit.nl>\n"
     
    104104
    105105#. Plugin Name of the plugin/theme
    106 #: promissa.php:97 promissa.php:98
     106#: promissa.php:86 promissa.php:87
    107107msgid "Pro Missa"
    108108msgstr ""
  • promissa/trunk/promissa.php

    r2207322 r2207376  
    44    Plugin URI: https://www.promissa.nl/plugins/wordpress
    55    Description: This plugin will give you shortcodes and widgets with the latest masses and events of Pro Missa.
    6     Version: 1.2.4
     6    Version: 1.2.5
    77    Author: Kerk en IT
    88    Author URI: https://www.kerkenit.nl
    99    Text Domain: promissa
    10     Domain Path: languages
     10    Domain Path: /languages
    1111    License: GPL2
    1212*/
     
    2828    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA   02110-1301  USA
    2929*/
     30setlocale(LC_ALL, get_locale());
    3031
    31 if ( ! defined( 'PROMISSA_FILE' ) ) {
     32if (!defined( 'PROMISSA_FILE' ) )
     33{
    3234    define( 'PROMISSA_FILE', __FILE__ );
    3335}
    3436
    35 if ( ! defined( 'PROMISSA_PATH' ) ) {
    36     define( 'PROMISSA_PATH', plugin_dir_path( PROMISSA_FILE ) );
    37 }
    38 
    39 if ( ! defined( 'PROMISSA_BASENAME' ) ) {
    40     define( 'PROMISSA_BASENAME', plugin_basename( PROMISSA_FILE ) );
    41 }
    42 
    43 if ( ! defined( 'PROMISSA_URL' ) ) {
    44     define( 'PROMISSA_URL', plugin_dir_url( PROMISSA_FILE) );
    45 }
    46 
    47 if ( ! defined( 'PROMISSA_SLUG' ) ) {
    48     define( 'PROMISSA_SLUG', 'promissa' );
    49 }
    50 
    51 if ( ! defined( 'PROMISSA_NAME' ) ) {
    52     define( 'PROMISSA_NAME', 'promissa' );
    53 }
    54 
    55 if ( ! defined( 'PROMISSA_LANG' ) ) {
    56     //define( 'PROMISSA_LANG', basename( dirname(__FILE__) ).'/languages/' );
    57     define( 'PROMISSA_LANG', PROMISSA_NAME . '/languages/' );
    58 }
    59 load_plugin_textdomain( 'promissa', false, PROMISSA_LANG );
    60 
    61 class ProMissa {
    62 
    63     static function init() {
    64         global $wpdb;
    65         load_plugin_textdomain( 'promissa', false, basename( dirname(__FILE__) ).'/languages/' );
    66 
    67     }
    68     static function activation() {
    69         self::init();
    70     }
    71     static function deactivation() {
    72         return true;
    73     }
    74     static function uninstall() {
    75         self::init();
    76     }
    77 }
    78 register_activation_hook( PROMISSA_FILE, array( 'ProMissa', 'activation' ) );
    79 register_deactivation_hook( PROMISSA_FILE, array( 'ProMissa', 'deactivation' ) );
    80 register_uninstall_hook( PROMISSA_FILE, array( 'ProMissa', 'uninstall' ) );
    81 
    82 
    83 if (!function_exists('ProMissa_add_menu_items')) {
    84 
    85     function ProMissa_add_menu_items() {
     37if (!function_exists('ProMissa_add_menu_items'))
     38{
     39    function ProMissa_add_menu_items()
     40    {
    8641         add_options_page(
    8742                __('Pro Missa', 'promissa'),
     
    10358}
    10459
    105 if (!function_exists('ProMissa_init')) {
    106     function ProMissa_init() {
     60if (!function_exists('ProMissa_init'))
     61{
     62    function ProMissa_init()
     63    {
    10764        require_once( dirname( PROMISSA_FILE) . '/functions.php' );
    10865        require_once( dirname( PROMISSA_FILE) . '/admin/settings.php' );
     
    11067}
    11168
    112 function register_ProMissa_parish_widgets() {
     69function register_ProMissa_widgets()
     70{
    11371    register_widget( 'ProMissa_UpcommingMassTimes_Widget' );
    11472}
     
    11876    add_action('wp_footer', 'flush_ob_end');
    11977endif;
     78
    12079add_action('init', 'ProMissa_init');
    12180add_action('admin_menu', 'ProMissa_add_menu_items');
    122 add_action('widgets_init', 'register_ProMissa_parish_widgets' );
     81add_action('widgets_init', 'register_ProMissa_widgets' );
    12382?>
  • promissa/trunk/readme.txt

    r2207322 r2207376  
    99Requires at least: 5.2.1
    1010Tested up to: 5.3
    11 Stable tag: 1.2.4
     11Stable tag: 1.2.5
    1212Requires PHP: 5.2.4
     13Requires at least: 4.6
    1314
    1415This plugin will give you shortcodes and widgets with the latest masses and events of Pro Missa.
     
    1617== Description ==
    1718
    18 This plugin will show all the times of masses who are stored in ProMissa.
     19This plugin will show all the times of masses who are stored in Pro Missa.
    1920This plugins will enable a shortcode and a widget with the upcoming events in your parish.
    2021You can add multiple widgets to your theme of add a shortcode in you homepage.
     
    8081== Changelog ==
    8182
     83= 1.2.5 =
     84
     85* Translations
     86* Optimised code
     87
    8288= 1.2.4 =
    8389
  • promissa/trunk/shortcodes/calendar.php

    r2207291 r2207376  
    11<?php
    22    define('FULLCALENDER', '4.2.0');
    3     setlocale(LC_ALL, 'nl_NL');
    43    $ProMissaEvents = array();
    54if(!function_exists('promissa_calendar_handler')) :
    6     function promissa_calendar_handler( $atts, $content = null ) {
    7         load_plugin_textdomain( 'promissa', false, PROMISSA_LANG);
     5    function promissa_calendar_handler( $atts, $content = null )
     6    {
    87        $atts_extended = shortcode_atts( array(
    98            'church_id' => '',
     
    2120        else :
    2221            $masses = ProMissaREST('Calendar', '?size=' . $limit);
     22
     23            //var_dump($masses);
    2324        endif;
    2425        $output = '';
     
    4344        wp_enqueue_script( 'fullcalender-daygrid', 'https://cdnjs.cloudflare.com/ajax/libs/fullcalendar/' . FULLCALENDER . '/daygrid/main.min.js', array ( 'fullcalender-core' ), FULLCALENDER, true);
    4445        wp_enqueue_script( 'fullcalender-timegrid', 'https://cdnjs.cloudflare.com/ajax/libs/fullcalendar/' . FULLCALENDER . '/timegrid/main.min.js', array ( 'fullcalender-core' ), FULLCALENDER, true);
    45         //wp_enqueue_script( 'fullcalender-list', 'https://cdnjs.cloudflare.com/ajax/libs/fullcalendar/' . FULLCALENDER . '/list/main.min.js', array ( 'fullcalender-core' ), FULLCALENDER, true);
    4646        wp_enqueue_script( 'popper', 'https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.15.0/umd/popper.min.js', array ( 'jquery' ), '1.15.0', true);
    4747        wp_enqueue_script( 'tooltip', 'https://cdnjs.cloudflare.com/ajax/libs/tooltip.js/1.3.2/umd/tooltip.min.js', array ( 'popper' ), '1.3.2', true);
     
    5252        wp_enqueue_style( 'fullcalender', 'https://cdnjs.cloudflare.com/ajax/libs/fullcalendar/' . FULLCALENDER . '/daygrid/main.min.css', false,FULLCALENDER,'all');
    5353        wp_enqueue_style( 'fullcalender', 'https://cdnjs.cloudflare.com/ajax/libs/fullcalendar/' . FULLCALENDER . '/timegrid/main.min.css', false,FULLCALENDER,'all');
    54         //wp_enqueue_style( 'fullcalender', 'https://cdnjs.cloudflare.com/ajax/libs/fullcalendar/' . FULLCALENDER . '/list/main.min.css', false,FULLCALENDER,'all');
    55 
    56 
    5754
    5855        if(count($masses) > 0) :
     56            $dateFormatter = \IntlDateFormatter::create(
     57                Locale::getDefault(),
     58                IntlDateFormatter::NONE,
     59                IntlDateFormatter::NONE,
     60                date_default_timezone_get(),
     61                IntlDateFormatter::GREGORIAN,
     62                'cccc d MMMM Y'
     63            );
    5964
    60         $dateFormatter = \IntlDateFormatter::create(
    61                   Locale::getDefault(),
    62                   IntlDateFormatter::NONE,
    63                   IntlDateFormatter::NONE,
    64                   date_default_timezone_get(),
    65                   IntlDateFormatter::GREGORIAN,
    66                   'cccc d MMMM Y'
    67                 );
    6865            foreach($masses as $mass)
    6966            {
     
    7572                $ProMissaEvents[] = array(
    7673                        'id' => $mass['ID'],
    77                         'title' => $mass['massType'] . ' (' . (strlen($mass['short']) > 2 ?  substr($mass['short'], 0, 2) : $mass['short']) . ')',
     74                        'title' =>  (!empty($mass['note']) ? $mass['note'] : $mass['massType']) . ' (' . (strlen($mass['short']) > 2 ?  substr($mass['short'], 0, 2) : $mass['short']) . ')',
    7875                        //'tooltip' =>  "<span><strong>" . (!empty($mass['note']) ? $mass['massType'] : (!empty($mass['memo']) ? Trim($mass['memo']) : Trim($mass['massType']))) . "</strong></span><br />Locatie: <strong>" . $mass['church'] . "</strong><br />Datum: <strong>" . $dateFormatter->format($date) . "</strong><br />Aanvang: <strong>" .$date->format('H.i\\u') . "</strong>",
    79                         'tooltip' =>  "<table><tr><th colspan=\"2\">" . (!empty($mass['note']) ? $mass['note'] : (!empty($mass['memo']) ? Trim($mass['memo']) : Trim($mass['massType']))) . "</th></tr><tr><td>" . __('Location', 'promissa') . ": </td><td>" . $mass['church'] . "</td></tr><tr><td>" . __('Date', 'promissa') . ": </td><td>" . $dateFormatter->format($date) . "</td></tr><tr><td>" . __('Time', 'promissa') . ": </td><td>" .$date->format('H.i\\u') . "</td></tr></table>",
     76                        'tooltip' =>  "<table><tr><th colspan=\"2\">" . (!empty($mass['note']) ? $mass['note'] : (!empty($mass['memo']) ? Trim($mass['memo']) : Trim($mass['massType']))) . "</th></tr><tr><td>" . __('Location', 'promissa') . ": </td><td>" . $mass['church'] . "</td></tr><tr><td>" . __('Date', 'promissa') . ": </td><td>" . $dateFormatter->format($date) . "</td></tr><tr><td>" . __('Time', 'promissa') . ": </td><td>" .$date->format('H.i\\u') . "</td></tr>" .
     77                        (!empty($mass['note']) && !empty($mass['memo']) ?
     78                        "<tr><td>" . __('Note', 'promissa') . ": </td><td>" . Trim($mass['memo']) . "</td></tr>" : "") .
     79                        "</table>",
    8080
    8181                        'start' => jsDateTime($mass['start']),
     
    8989            $output = json_encode($ProMissaEvents);
    9090
    91 
    92 
    9391            return '<div id="calendar"></div>';
    9492        endif;
     
    9896    }
    9997endif;
     98
    10099function footer_script(){
    101100    global $ProMissaEvents; ?>
     
    104103
    105104add_action('wp_footer', 'footer_script');
    106 
    107 function head_style(){ ?>
    108 <style type="text/css" media="screen">
    109 
    110 
    111 </style>
    112 <?php }
    113105add_action(
    114106    'wp_enqueue_scripts',
     
    127119}
    128120
    129 remove_shortcode( 'promissa-calendar' );
    130121add_shortcode( 'promissa-calendar', 'promissa_calendar_handler' );
    131122?>
  • promissa/trunk/shortcodes/css/popper.css

    r2188531 r2207376  
    1 .popper,.tooltip{position:absolute;z-index:9999;background:rgba(0,0,0,.75);color:#FFFFFF;min-width:150px;border-radius:3px;box-shadow:0 0 2px rgba(0,0,0,0.5);padding:10px;text-align:left}.style5 .tooltip{background:#333;color:#FFFFFF;max-width:200px;width:auto;font-size:0.8rem;padding:0.5em 1em}.popper .popper__arrow,.tooltip .tooltip-arrow{width:0;height:0;border-style:solid;position:absolute;margin:5px}.popper .popper__arrow,.tooltip .tooltip-arrow{border-color:#333}.style5 .tooltip .tooltip-arrow{border-color:#222}.popper[x-placement^="top"],.tooltip[x-placement^="top"]{margin-bottom:5px}.popper[x-placement^="top"] .popper__arrow,.tooltip[x-placement^="top"] .tooltip-arrow{border-width:5px 5px 0 5px;border-left-color:transparent;border-right-color:transparent;border-bottom-color:transparent;bottom:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0}.popper[x-placement^="bottom"],.tooltip[x-placement^="bottom"]{margin-top:5px}.tooltip[x-placement^="bottom"] .tooltip-arrow,.popper[x-placement^="bottom"] .popper__arrow{border-width:0 5px 5px 5px;border-left-color:transparent;border-right-color:transparent;border-top-color:transparent;top:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0}.tooltip[x-placement^="right"],.popper[x-placement^="right"]{margin-left:5px}.popper[x-placement^="right"] .popper__arrow,.tooltip[x-placement^="right"] .tooltip-arrow{border-width:5px 5px 5px 0;border-left-color:transparent;border-top-color:transparent;border-bottom-color:transparent;left:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0}.popper[x-placement^="left"],.tooltip[x-placement^="left"]{margin-right:5px}.popper[x-placement^="left"] .popper__arrow,.tooltip[x-placement^="left"] .tooltip-arrow{border-width:5px 0 5px 5px;border-top-color:transparent;border-right-color:transparent;border-bottom-color:transparent;right:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0}.tooltip-inner table tr th{font-size:125%;text-align:center}.tooltip-inner table,.tooltip-inner table tr,.tooltip-inner table tr > td,.tooltip-inner table tr > th{border:none !important}#calendar .fc-timeGridDay-view .fc-content-skeleton,#calendar .fc-timeGridWeek-view .fc-content-skeleton{position:absolute;top:0}#calendar .fc-list-view .fc-list-heading-alt{margin-left:3px}#calendar table,#calendar table tbody,#calendar table tbody tr,#calendar table tbody tr td,#calendar table thead,#calendar table thead tr,#calendar table thead tr td{background:transparent !important}#calendar table tbody tr td{border:1px solid #ddd !important}#calendar table{margin-bottom:0 !important}
     1.popper,.tooltip{position:absolute;z-index:9999;background:rgba(0,0,0,.75);color:#FFFFFF;min-width:150px;border-radius:3px;box-shadow:0 0 2px rgba(0,0,0,0.5);padding:10px;text-align:left}.style5 .tooltip{background:#333;color:#FFFFFF;max-width:200px;width:auto;font-size:0.8rem;padding:0.5em 1em}.popper .popper__arrow,.tooltip .tooltip-arrow{width:0;height:0;border-style:solid;position:absolute;margin:5px}.popper .popper__arrow,.tooltip .tooltip-arrow{border-color:#333}.style5 .tooltip .tooltip-arrow{border-color:#222}.popper[x-placement^="top"],.tooltip[x-placement^="top"]{margin-bottom:5px}.popper[x-placement^="top"] .popper__arrow,.tooltip[x-placement^="top"] .tooltip-arrow{border-width:5px 5px 0 5px;border-left-color:transparent;border-right-color:transparent;border-bottom-color:transparent;bottom:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0}.popper[x-placement^="bottom"],.tooltip[x-placement^="bottom"]{margin-top:5px}.tooltip[x-placement^="bottom"] .tooltip-arrow,.popper[x-placement^="bottom"] .popper__arrow{border-width:0 5px 5px 5px;border-left-color:transparent;border-right-color:transparent;border-top-color:transparent;top:-5px;left:calc(50% - 5px);margin-top:0;margin-bottom:0}.tooltip[x-placement^="right"],.popper[x-placement^="right"]{margin-left:5px}.popper[x-placement^="right"] .popper__arrow,.tooltip[x-placement^="right"] .tooltip-arrow{border-width:5px 5px 5px 0;border-left-color:transparent;border-top-color:transparent;border-bottom-color:transparent;left:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0}.popper[x-placement^="left"],.tooltip[x-placement^="left"]{margin-right:5px}.popper[x-placement^="left"] .popper__arrow,.tooltip[x-placement^="left"] .tooltip-arrow{border-width:5px 0 5px 5px;border-top-color:transparent;border-right-color:transparent;border-bottom-color:transparent;right:-5px;top:calc(50% - 5px);margin-left:0;margin-right:0}.tooltip-inner table tr th{font-size:125%;text-align:center}.tooltip-inner table,.tooltip-inner table tr,.tooltip-inner table tr > td,.tooltip-inner table tr > th{border:none !important}#calendar .fc-timeGridDay-view .fc-content-skeleton,#calendar .fc-timeGridWeek-view .fc-content-skeleton{position:absolute;top:0}#calendar .fc-list-view .fc-list-heading-alt{margin-left:3px}#calendar table,#calendar table tbody,#calendar table tbody tr,#calendar table tbody tr td,#calendar table thead,#calendar table thead tr,#calendar table thead tr td{background:transparent !important}#calendar table tbody tr td.fc-today{background:#fcf8e3 !important;}#calendar table tbody tr td{border:1px solid #ddd !important}#calendar table{margin-bottom:0 !important}
  • promissa/trunk/shortcodes/upcoming_mass.php

    r2136288 r2207376  
    11<?php
    22
    3 
    4     setlocale(LC_ALL, 'nl_NL');
    53if(!function_exists('promissa_upcoming_masses_handler')) :
    6     function promissa_upcoming_masses_handler( $atts, $content = null ) {
    7         load_plugin_textdomain( 'promissa', false, PROMISSA_LANG);
     4    function promissa_upcoming_masses_handler( $atts, $content = null )
     5    {
    86        $atts_extended = shortcode_atts( array(
    97            'church_id' => '',
     
    9189    }
    9290endif;
    93 remove_shortcode( 'promissa-upcoming-masses' );
    9491add_shortcode( 'promissa-upcoming-masses', 'promissa_upcoming_masses_handler' );
    9592?>
  • promissa/trunk/widgets/upcoming_mass.php

    r2136288 r2207376  
    88     * Register widget with WordPress.
    99     */
    10     function __construct() {
    11 
    12         load_plugin_textdomain( 'promissa', false, PROMISSA_LANG);
     10    function __construct()
     11    {
    1312        $widget_ops = array('classname' => 'promissa_widget_masses promissa_upcoming_masses', 'description' => __( 'This widget will show the upcoming mass times. This is recommended if your primary target audience are seekers to faith.', 'promissa' ));
    1413        parent::__construct(
Note: See TracChangeset for help on using the changeset viewer.