Plugin Directory

Changeset 3351165


Ignore:
Timestamp:
08/27/2025 11:49:57 AM (6 months ago)
Author:
leodesouza
Message:

Get-It-On: On-Page Features, Check the basic informations of Pages, Posts and Products.

Location:
xpose-content
Files:
46 added
2 edited

Legend:

Unmodified
Added
Removed
  • xpose-content/trunk/readme.txt

    r3326330 r3351165  
    55Requires at least: 6.1
    66Tested up to: 6.8
    7 Stable tag: 0.9.9
     7Stable tag: 0.9.10
    88License: GPLv2 or later 
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    4545
    4646## Changelog
     47### 0.9.10
     48* Get-It-On: On-Page Features, Check the basic informations of Pages, Posts and Products.
    4749### 0.9.9
    4850* Is Classified: Improvements in the Code, and the new Visual Identity of the XC.
  • xpose-content/trunk/xpose-content.php

    r3326330 r3351165  
    44 * Plugin URI:        https://xposecontent.com/
    55 * Description:       Xpose Content is a tool for managers who want to view and manage all the content of a site, blog or ecommerce project. Check the main metrics related to published content and export them to spreadsheets.
    6  * Version:           0.9.9
     6 * Version:           0.9.10
    77 * Author:            Leonardo de Souza
    8  * Author URI:        https://gestordeconteudo.com/
     8 * Author URI:        https://grunge.com.br/
    99 * License:           GPL v2 or later
    1010 * License URI:       https://www.gnu.org/licenses/gpl-2.0.html
     
    6969    'XC Products',
    7070    'manage_options',
    71     'xc-prodcuts',
     71    'xc-products',
    7272    'xpco_products'
    7373    );
     
    8080    'xpco_custom'
    8181    );
     82    add_submenu_page(
     83    null,
     84    'Posts OnPage',
     85    'XC Posts OnPage',
     86    'manage_options',
     87    'xc-posts-onpage',
     88    'xpco_posts_onpage'
     89    );
     90    add_submenu_page(
     91    null,
     92    'Pages OnPage',
     93    'XC Pages OnPage',
     94    'manage_options',
     95    'xc-pages-onpage',
     96    'xpco_pages_onpage'
     97    );
     98    add_submenu_page(
     99    null,
     100    'Products OnPage',
     101    'XC Products OnPage',
     102    'manage_options',
     103    'xc-products-onpage',
     104    'xpco_products_onpage'
     105    );
     106    add_submenu_page(
     107    null,
     108    'Custom OnPage',
     109    'XC Custom OnPage',
     110    'manage_options',
     111    'xc-custom-posts-onpage',
     112    'xpco_custom_posts_onpage'
     113    );
     114}
     115
     116// Admin Submenu
     117add_action( 'admin_head', 'xpco_force_open_menu' );
     118function xpco_force_open_menu() {
     119    global $plugin_page, $submenu_file;
     120    $onpage_list = array(
     121        'xc-posts-onpage'        => 'xc-posts',
     122        'xc-pages-onpage'        => 'xc-pages',
     123        'xc-products-onpage'     => 'xc-products',
     124        'xc-custom-posts-onpage' => 'xc-custom',
     125    );
     126    if ( isset($_GET['page']) ) {
     127        $page = sanitize_key( wp_unslash( $_GET['page'] ) );
     128        if ( isset($onpage_list[$page]) ) {
     129            $plugin_page  = 'xc-dashboard';
     130            $submenu_file = $onpage_list[$page];
     131        }
     132    }
    82133}
    83134
     
    95146add_action( 'init', 'xpco_posts_export' );
    96147
     148function xpco_posts_onpage(){
     149    require_once( plugin_dir_path( __FILE__ ) . 'views/xc-posts-onpage.php' );
     150}
     151
    97152function xpco_pages(){
    98153    require_once( plugin_dir_path( __FILE__ ) . 'views/xc-pages.php' );
     
    104159add_action( 'init', 'xpco_pages_export' );
    105160
     161function xpco_pages_onpage(){
     162    require_once( plugin_dir_path( __FILE__ ) . 'views/xc-pages-onpage.php' );
     163}
     164
    106165function xpco_products(){
    107166    require_once( plugin_dir_path( __FILE__ ) . 'views/xc-products.php' );
     
    113172add_action( 'init', 'xpco_products_export' );
    114173
     174function xpco_products_onpage(){
     175    require_once( plugin_dir_path( __FILE__ ) . 'views/xc-products-onpage.php' );
     176}
     177
    115178function xpco_custom(){
    116179    require_once( plugin_dir_path( __FILE__ ) . 'views/xc-custom.php' );
     
    122185add_action( 'init', 'xpco_custom_export' );
    123186
     187function xpco_custom_posts_onpage(){
     188    require_once( plugin_dir_path( __FILE__ ) . 'views/xc-custom-posts-onpage.php' );
     189}
     190
    124191// Used Styles
    125192function xpose_content_stylesheets(){
    126     // Define The Version as a Timestamp or a Static Version Number
    127     $version = '0.9.9';
    128     // Enqueue The Styles With Versioning
     193    $version = '0.9.10';
    129194    wp_enqueue_style( 'xc-styles', plugins_url( '/assets/css/xc-styles.css', __FILE__ ), array(), $version );
    130195    wp_enqueue_style( 'xc-all', plugins_url( '/assets/css/xc-all.css', __FILE__ ), array(), $version );
     
    137202}
    138203add_action( 'init', 'xpose_content_load_textdomain' );
     204
     205// Description Links
     206add_filter( 'plugin_row_meta', 'xpose_content_meta_links', 10, 2 );
     207function xpose_content_meta_links( $xc_links, $file ) {
     208    if ( plugin_basename(__FILE__) == $file ) {
     209        $xc_links[] = '<a href="' . esc_url( 'https://www.amazon.com.br/dp/B0FGFGL13X' ) . '" target="_blank">' . esc_html( 'Check my Book' ) . '</a>';
     210    }
     211    return $xc_links;
     212}
    139213?>
Note: See TracChangeset for help on using the changeset viewer.