Plugin Directory

Changeset 2855031


Ignore:
Timestamp:
01/26/2023 09:14:05 AM (3 years ago)
Author:
potreb
Message:

added suport for WP 6.1

Location:
category-custom-post-order
Files:
18 added
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • category-custom-post-order/trunk/category-custom-post-order.php

    r2225811 r2855031  
    11<?php
    22/**
    3  * Plugin Name: Posts Order
    4  * Version: 1.4.5
    5  * Plugin URI: http://wpsmartlab.com/
     3 * Plugin Name: Order Posts per Taxonomy
    64 * Description: Order posts separately for each taxonomy
    7  * Author: Piotr Potrebka
    8  * Author URI:  http://wpsmartlab.com/
    9  * License:     GPL v2 or later
     5 * Version: 1.5.0
     6 * Plugin URI: https://wpsmartlab.com/
     7 * Author: WPSmartLab
     8 * Author URI: https://wpsmartlab.com/
     9 * Text Domain: cps
     10 * Domain Path: /languages/
     11 * Requires at least: 5.5
     12 * Tested up to: 6.1
     13 * Requires PHP: 7.0
     14 * License: GPL v2 or later
    1015 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
    11  * Domain Path: /languages
    12 */
     16 */
    1317
    1418// Exit if accessed directly
     19
     20use WPSL\PostsOrder\Dashboard\Settings;
     21use WPSL\PostsOrder\PostsOrder;
     22
    1523defined( 'ABSPATH' ) || exit;
    1624
    17 /**
    18  * Instantiate the main Posts Order class
    19  *
    20  * @since 0.1.0
    21  */
    22 function _posts_order() {
     25function wpsl_posts_order() {
     26    $file = __FILE__;
     27    load_plugin_textdomain( 'cps', false, basename( dirname( $file ) ) . '/languages' );
     28    include dirname( $file ) . '/src/PostsOrder.php';
     29    include dirname( $file ) . '/src/Dashboard/Settings.php';
     30    if ( is_admin() ) {
     31        new Settings();
     32    }
     33    new PostsOrder( $file );
     34}
    2335
    24     // Setup the main file
    25     $file = __FILE__;
    26 
    27     // Locad localization file
    28     load_plugin_textdomain( 'cps', false, basename( dirname( $file ) ) . '/languages' );
    29    
    30     // Include the main class
    31     include dirname( $file ) . '/includes/admin_settings.php';
    32     include dirname( $file ) . '/includes/posts_order.php';
    33    
    34     // Instantiate settings
    35     if( is_admin() ) new Post_Order_Settings();
    36     // Instantiate the main class
    37     new Posts_Order( $file );
    38 }
    39 add_action( 'init', '_posts_order', 99 );
     36add_action( 'plugins_loaded', 'wpsl_posts_order', 99 );
  • category-custom-post-order/trunk/readme.txt

    r2236473 r2855031  
    33Tags: posts order, custom post order, post order, category post order, taxonomy post order, order posts by category
    44Donate link: http://schronisko.info.pl/kontakt-schronisko/numer-konta
    5 Requires at least: 4.6
    6 Tested up to: 5.3.2
    7 Stable tag: 1.4.6
     5Requires at least: 5.5
     6Tested up to: 6.1.1
     7Stable tag: 1.5.0
    88License: GPL2
    99License URI: https://wordpress.org/about/gpl/
     
    1616You can order yours post by date, modyfication date, title, id, author, slug, postmeta or custom
    1717
    18 [youtube https://www.youtube.com/watch?v=8jvNn4V9nq8]
    19 
    2018== Installation ==
    21191. Upload the entire category-custom-post-order folder to the /wp-content/plugins/ directory.
     
    2422
    2523== Changelog ==
     24= 1.5.0 =
     25* Added support for WordPress 6.1
     26
    2627= 1.4.6 =
    2728* Fixed sorting for custom taxonomies
Note: See TracChangeset for help on using the changeset viewer.