Make WordPress Themes

Changeset 313061


Ignore:
Timestamp:
02/12/2026 05:28:39 AM (9 months ago)
Author:
themedropbox
Message:

New version of Sports Agency - 0.1.4

Location:
sports-agency/0.1.4
Files:
13 edited
1 copied

Legend:

Unmodified
Added
Removed
  • sports-agency/0.1.4/functions.php

    r304405 r313061  
    385385}
    386386
     387add_filter( 'woocommerce_single_product_image_thumbnail_html', function( $html ) {
     388    return '<div class="product-img">' . $html . '</div>';
     389});
     390
    387391/**
    388392 * Change number or products per row to 4
  • sports-agency/0.1.4/includes/color-setting/custom-color-control.php

    r278457 r313061  
    4242        $sports_agency_theme_custom_setting_css .='}';
    4343    }
     44
     45    // Featured Image Hover Effect
     46    $sports_agency_show_featured = get_theme_mod('sports_agency_featured_image_hide_show', 1);
     47    $sports_agency_hover_effect = get_theme_mod('sports_agency_single_post_featured_image_hover','none');
     48
     49    if ( $sports_agency_show_featured && $sports_agency_hover_effect !== 'none' ) {
     50
     51    $sports_agency_theme_custom_setting_css .= '
     52    .post-img img{
     53        transition: all 0.4s ease;
     54    }';
     55
     56    if ( $sports_agency_hover_effect === 'zoom-in' ) {
     57        $sports_agency_theme_custom_setting_css .= '
     58        .post-img:hover img{
     59            transform: scale(1.2);
     60        }';
     61    }
     62
     63    if ( $sports_agency_hover_effect === 'zoom-out' ) {
     64        $sports_agency_theme_custom_setting_css .= '
     65        .post-img img{ transform: scale(1.2); }
     66        .post-img:hover img{ transform: scale(1); }';
     67    }
     68
     69    if ( $sports_agency_hover_effect === 'grayscale' ) {
     70        $sports_agency_theme_custom_setting_css .= '
     71        .post-img img{ filter: grayscale(100%); }
     72        .post-img:hover img{ filter: grayscale(0); }';
     73    }
     74
     75    if ( $sports_agency_hover_effect === 'sepia' ) {
     76        $sports_agency_theme_custom_setting_css .= '
     77        .post-img:hover img{ filter: sepia(100%); }';
     78    }
     79
     80    if ( $sports_agency_hover_effect === 'blur' ) {
     81        $sports_agency_theme_custom_setting_css .= '
     82        .post-img:hover img{ filter: blur(3px); }';
     83    }
     84
     85    if ( $sports_agency_hover_effect === 'bright' ) {
     86        $sports_agency_theme_custom_setting_css .= '
     87        .post-img:hover img{ filter: brightness(1.3); }';
     88    }
     89
     90    if ( $sports_agency_hover_effect === 'translate' ) {
     91        $sports_agency_theme_custom_setting_css .= '
     92        .post-img:hover img{ transform: translateY(-10px); }';
     93    }
     94
     95    if ( $sports_agency_hover_effect === 'scale' ) {
     96        $sports_agency_theme_custom_setting_css .= '
     97        .post-img:hover img{ transform: scale(1.1); }';
     98    }
     99}
     100// Product Featured Image Hover Effect
     101    $sports_agency_show_featured = get_theme_mod('sports_agency_featured_image_hide_show', 1);
     102    $sports_agency_hover_effect = get_theme_mod('sports_agency_product_featured_image_hover','none');
     103
     104    if ( $sports_agency_show_featured && $sports_agency_hover_effect !== 'none' ) {
     105
     106    $sports_agency_theme_custom_setting_css .= '
     107    .product-img img{
     108        transition: all 0.4s ease;
     109    }';
     110
     111    if ( $sports_agency_hover_effect === 'zoom-in' ) {
     112        $sports_agency_theme_custom_setting_css .= '
     113        .product-img:hover img{
     114            transform: scale(1.2);
     115        }';
     116    }
     117
     118    if ( $sports_agency_hover_effect === 'zoom-out' ) {
     119        $sports_agency_theme_custom_setting_css .= '
     120        .product-img img{ transform: scale(1.2); }
     121        .product-img:hover img{ transform: scale(1); }';
     122    }
     123
     124    if ( $sports_agency_hover_effect === 'grayscale' ) {
     125        $sports_agency_theme_custom_setting_css .= '
     126        .product-img img{ filter: grayscale(100%); }
     127        .product-img:hover img{ filter: grayscale(0); }';
     128    }
     129
     130    if ( $sports_agency_hover_effect === 'sepia' ) {
     131        $sports_agency_theme_custom_setting_css .= '
     132        .product-img:hover img{ filter: sepia(100%); }';
     133    }
     134
     135    if ( $sports_agency_hover_effect === 'blur' ) {
     136        $sports_agency_theme_custom_setting_css .= '
     137        .product-img:hover img{ filter: blur(3px); }';
     138    }
     139
     140    if ( $sports_agency_hover_effect === 'bright' ) {
     141        $sports_agency_theme_custom_setting_css .= '
     142        .product-img:hover img{ filter: brightness(1.3); }';
     143    }
     144
     145    if ( $sports_agency_hover_effect === 'translate' ) {
     146        $sports_agency_theme_custom_setting_css .= '
     147        .product-img:hover img{ transform: translateY(-10px); }';
     148    }
     149
     150    if ( $sports_agency_hover_effect === 'scale' ) {
     151        $sports_agency_theme_custom_setting_css .= '
     152        .product-img:hover img{ transform: scale(1.1); }';
     153    }
     154}   
  • sports-agency/0.1.4/includes/customizer.php

    r298953 r313061  
    679679                ),
    680680        ] );
     681
     682        Kirki::add_field( 'theme_config_id', [
     683    'type'     => 'custom',
     684    'settings' => 'sports_agency_show_product_featured_image_hover_heading',
     685    'section'  => 'sports_agency_woocommerce_settings',
     686    'default'  => '<h3 style="color: #2271b1; padding:10px; background:#fff; margin:0; border-left: solid 5px #2271b1;">' . __( 'Product Featured Image Hover Effect', 'sports-agency' ) . '</h3>',
     687    'priority' => 20,
     688   ] );
     689
     690        Kirki::add_field( 'theme_config_id', [
     691    'type'     => 'select',
     692    'settings' => 'sports_agency_product_featured_image_hover',
     693    'label'    => esc_html__( 'Product Featured Image Hover Effect', 'sports-agency' ),
     694    'section'  => 'sports_agency_woocommerce_settings',
     695    'default'  => 'none',
     696    'priority' => 30,
     697    'choices'  => [
     698        'none'      => esc_html__( 'None', 'sports-agency' ),
     699        'zoom-in'   => esc_html__( 'Zoom In', 'sports-agency' ),
     700        'zoom-out'  => esc_html__( 'Zoom Out', 'sports-agency' ),
     701        'scale'     => esc_html__( 'Scale', 'sports-agency' ),
     702        'grayscale' => esc_html__( 'Grayscale', 'sports-agency' ),
     703        'blur'      => esc_html__( 'Blur', 'sports-agency' ),
     704        'bright'    => esc_html__( 'Bright', 'sports-agency' ),
     705        'sepia'     => esc_html__( 'Sepia', 'sports-agency' ),
     706        'translate' => esc_html__( 'Translate', 'sports-agency' ),
     707    ],
     708    ] );
    681709       
    682710        //ADDITIONAL SETTINGS
    … …  
    12621290
    12631291        Kirki::add_field( 'theme_config_id', [
     1292        'type'     => 'select',
     1293        'tab'      => 'single-post',
     1294        'settings' => 'sports_agency_single_post_featured_image_hover',
     1295        'label'    => esc_html__( 'Featured Image Hover Effect', 'sports-agency' ),
     1296        'section'  => 'sports_agency_blog_post',
     1297        'default'  => 'none',
     1298        'priority' => 20,
     1299        'choices'  => [
     1300                'none'      => esc_html__( 'None', 'sports-agency' ),
     1301                'zoom-in'   => esc_html__( 'Zoom In', 'sports-agency' ),
     1302                'zoom-out'  => esc_html__( 'Zoom Out', 'sports-agency' ),
     1303                'scale'     => esc_html__( 'Scale', 'sports-agency' ),
     1304                'grayscale' => esc_html__( 'Grayscale', 'sports-agency' ),
     1305                'blur'      => esc_html__( 'Blur', 'sports-agency' ),
     1306                'bright'    => esc_html__( 'Bright', 'sports-agency' ),
     1307                'sepia'     => esc_html__( 'Sepia', 'sports-agency' ),
     1308                'translate' => esc_html__( 'Translate', 'sports-agency' ),
     1309        ],
     1310    ] );
     1311
     1312        Kirki::add_field( 'theme_config_id', [
    12641313                'type'        => 'custom',
    12651314                'tab'      => 'single-post',
  • sports-agency/0.1.4/includes/getstart/getstart.css

    r304405 r313061  
    416416    background: #ff2c6f;
    417417}
    418 
     418.quick-btn a:hover{
     419    background:#2195af;
     420}
     421.premium-btn a:hover{
     422    background:#2195af;
     423}
     424.demo-btn a:hover{
     425    background:#2195af;
     426}
     427.doc-btn a:hover{
     428    background:#2195af;
     429}
    419430.premium-features ul li {
    420431    margin-bottom: 10px;
    … …  
    591602
    592603.sports-agency-recommended-plugins a.button:hover {
    593     border: 1px solid #1E2957;
    594     background: #1E2957;
     604    border: 1px solid #2195af;
     605    background: #2195af;
    595606}
    596607.sports-agency-recommended-plugins a.button:focus {
  • sports-agency/0.1.4/includes/getstart/getstart.php

    r304405 r313061  
    4545                $sports_agency_changelog_list = sports_agency_parse_changelog( $sports_agency_changelog );
    4646
    47                 // ✅ wrapper + button add kiya gaya hai
    4847                echo '<div id="sports-agency-changelog-container">';
    4948                echo wp_kses_post( $sports_agency_changelog_list );
  • sports-agency/0.1.4/includes/product-create.php

    r280800 r313061  
    156156        update_post_meta( $sports_agency_product_id, 'sports_agency_product_image_gallery', $sports_agency_product_image_gallery );
    157157        }
    158 }
    159 
     158
     159        /* Create Menu */
     160            $sports_agency_menuname  = 'Main Menus';
     161            $sports_agency_location  = 'main-menu';
     162
     163            $sports_agency_menu = wp_get_nav_menu_object( $sports_agency_menuname );
     164
     165            if ( ! $sports_agency_menu ) {
     166            $sports_agency_menu_id = wp_create_nav_menu( $sports_agency_menuname );
     167
     168           // Home Page
     169                        wp_update_nav_menu_item( $sports_agency_menu_id, 0, array(
     170                                'menu-item-title'     => __( 'Home', 'sports-agency' ),
     171                                'menu-item-url'       => home_url( '/' ),
     172                                'menu-item-type'      => 'custom',
     173                                'menu-item-status'    => 'publish',
     174                        ) );
     175
     176                        // About Us Page
     177                        $sports_agency_about_id = wp_insert_post( array(
     178                        'post_type'   => 'page',
     179                        'post_content' => 'We are committed to providing reliable, professional, and result-oriented solutions tailored to meet individual needs. Our goal is to empower people with the right guidance, knowledge, and support to help them make informed decisions for a better future. <br><br> Our mission is to deliver high-quality services with honesty, transparency, and dedication. We focus on understanding client requirements and offering practical solutions that create long-term value. <br><br> With a client-centric approach, experienced professionals, and a commitment to excellence, we ensure every individual receives the attention and guidance they deserve. We believe in building trust through quality service and consistent results.',
     180                        'post_title'  => 'About Us',
     181                        'post_status' => 'publish',
     182                        ) );
     183
     184                        if ( $sports_agency_about_id ) {
     185                        wp_update_nav_menu_item( $sports_agency_menu_id, 0, array(
     186                        'menu-item-title'     => 'About Us',
     187                        'menu-item-object'    => 'page',
     188                        'menu-item-object-id' => $sports_agency_about_id,
     189                        'menu-item-type'      => 'post_type',
     190                        'menu-item-status'    => 'publish',
     191                        ) );
     192                        }
     193
     194                        // Services Page
     195                        $sports_agency_about_id = wp_insert_post( array(
     196                        'post_type'   => 'page',
     197                        'post_content' => 'We are committed to providing reliable, professional, and result-oriented solutions tailored to meet individual needs. Our goal is to empower people with the right guidance, knowledge, and support to help them make informed decisions for a better future. <br><br> Our mission is to deliver high-quality services with honesty, transparency, and dedication. We focus on understanding client requirements and offering practical solutions that create long-term value. <br><br> With a client-centric approach, experienced professionals, and a commitment to excellence, we ensure every individual receives the attention and guidance they deserve. We believe in building trust through quality service and consistent results.',
     198                        'post_title'  => 'Services',
     199                        'post_status' => 'publish',
     200                        ) );
     201
     202                        if ( $sports_agency_about_id ) {
     203                        wp_update_nav_menu_item( $sports_agency_menu_id, 0, array(
     204                        'menu-item-title'     => 'Services',
     205                        'menu-item-object'    => 'page',
     206                        'menu-item-object-id' => $sports_agency_about_id,
     207                        'menu-item-type'      => 'post_type',
     208                        'menu-item-status'    => 'publish',
     209                        ) );
     210                        }
     211
     212                        // Contact Us Page
     213                        $sports_agency_about_id = wp_insert_post( array(
     214                        'post_type'   => 'page',
     215                        'post_content' => 'We are committed to providing reliable, professional, and result-oriented solutions tailored to meet individual needs. Our goal is to empower people with the right guidance, knowledge, and support to help them make informed decisions for a better future. <br><br> Our mission is to deliver high-quality services with honesty, transparency, and dedication. We focus on understanding client requirements and offering practical solutions that create long-term value. <br><br> With a client-centric approach, experienced professionals, and a commitment to excellence, we ensure every individual receives the attention and guidance they deserve. We believe in building trust through quality service and consistent results.',
     216                        'post_title'  => 'Contact Us',
     217                        'post_status' => 'publish',
     218                        ) );
     219
     220                        if ( $sports_agency_about_id ) {
     221                        wp_update_nav_menu_item( $sports_agency_menu_id, 0, array(
     222                        'menu-item-title'     => 'Contact Us',
     223                        'menu-item-object'    => 'page',
     224                        'menu-item-object-id' => $sports_agency_about_id,
     225                        'menu-item-type'      => 'post_type',
     226                        'menu-item-status'    => 'publish',
     227                        ) );
     228                        }
     229
     230          // Create Shop Page
     231                $sports_agency_about_title = 'Shop';
     232                $sports_agency_about_content = 'Lorem ipsum dolor sit amet...';
     233
     234                $shop_page = get_page_by_path('shop');
     235                if ( !$shop_page ) {
     236                    $sports_agency_about = array(
     237                        'post_type'   => 'page',
     238                        'post_title'  => $sports_agency_about_title,
     239                        'post_content'=> $sports_agency_about_content,
     240                        'post_status' => 'publish',
     241                        'post_author' => 1,
     242                        'post_name'   => 'shop'
     243                        );
     244                        $sports_agency_about_id = wp_insert_post($sports_agency_about);
     245                    } else {
     246                        $sports_agency_about_id = $shop_page->ID;
     247                    }
     248
     249                    wp_update_nav_menu_item($sports_agency_menu_id, 0, array(
     250                        'menu-item-title'   => __('Shop', 'sports-agency'),
     251                        'menu-item-classes' => 'shop',
     252                        'menu-item-object-id' => $sports_agency_about_id,
     253                        'menu-item-object'  => 'page',
     254                        'menu-item-type'    => 'post_type',
     255                        'menu-item-status'  => 'publish'
     256                    ));
     257           
     258                        /* Assign Menu Location */
     259                        $sports_agency_locations = get_theme_mod( 'nav_menu_locations', array() );
     260                        $sports_agency_locations[ $sports_agency_location ] = $sports_agency_menu_id;
     261                        set_theme_mod( 'nav_menu_locations', $sports_agency_locations );
     262                }
     263    }
    160264}
    161265 
  • sports-agency/0.1.4/includes/tgm/class-tgm-plugin-activation.php

    r278457 r313061  
    99 *
    1010 * @package   TGM-Plugin-Activation
    11  * @version   2.6.1 for parent theme Sports Agency for publication on WordPress.org
     11 * @version   2.6.1
    1212 * @link      http://tgmpluginactivation.com/
    1313 * @author    Thomas Griffin, Gary Jones, Juliette Reinders Folmer
    … …  
    3232        Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
    3333*/
     34
     35// Exit if accessed directly.
     36if ( ! defined( 'ABSPATH' ) ) {
     37        return;
     38}
    3439
    3540if ( ! class_exists( 'TGM_Plugin_Activation' ) ) {
    … …  
    260265                        do_action_ref_array( 'tgmpa_init', array( $this ) );
    261266
    262 
     267                        /*
     268                         * Load our text domain and allow for overloading the fall-back file.
     269                         *
     270                         * {@internal IMPORTANT! If this code changes, review the regex in the custom TGMPA
     271                         * generator on the website.}}
     272                         */
     273                        add_action( 'init', array( $this, 'load_textdomain' ), 5 );
     274                        add_filter( 'load_textdomain_mofile', array( $this, 'overload_textdomain_mofile' ), 10, 2 );
    263275
    264276                        // When the rest of WP has loaded, kick-start the rest of the class.
    … …  
    283295                 */
    284296                public function __set( $name, $value ) {
     297                        // phpcs:ignore Squiz.PHP.NonExecutableCode.ReturnNotRequired -- See explanation above.
    285298                        return;
    286299                }
    … …  
    332345                                'updating'                        => __( 'Updating Plugin: %s', 'sports-agency' ),
    333346                                'oops'                            => __( 'Something went wrong with the plugin API.', 'sports-agency' ),
     347                                /* translators: 1: plugin name(s). */
    334348                                'notice_can_install_required'     => _n_noop(
    335                                         /* translators: 1: plugin name(s). */
    336349                                        'This theme requires the following plugin: %1$s.',
    337350                                        'This theme requires the following plugins: %1$s.',
    338351                                        'sports-agency'
    339352                                ),
     353                                /* translators: 1: plugin name(s). */
    340354                                'notice_can_install_recommended'  => _n_noop(
    341                                         /* translators: 1: plugin name(s). */
    342355                                        'This theme recommends the following plugin: %1$s.',
    343356                                        'This theme recommends the following plugins: %1$s.',
    344357                                        'sports-agency'
    345358                                ),
     359                                /* translators: 1: plugin name(s). */
    346360                                'notice_ask_to_update'            => _n_noop(
    347                                         /* translators: 1: plugin name(s). */
    348361                                        'The following plugin needs to be updated to its latest version to ensure maximum compatibility with this theme: %1$s.',
    349362                                        'The following plugins need to be updated to their latest version to ensure maximum compatibility with this theme: %1$s.',
    350363                                        'sports-agency'
    351364                                ),
     365                                /* translators: 1: plugin name(s). */
    352366                                'notice_ask_to_update_maybe'      => _n_noop(
    353                                         /* translators: 1: plugin name(s). */
    354367                                        'There is an update available for: %1$s.',
    355368                                        'There are updates available for the following plugins: %1$s.',
    356369                                        'sports-agency'
    357370                                ),
     371                                /* translators: 1: plugin name(s). */
    358372                                'notice_can_activate_required'    => _n_noop(
    359                                         /* translators: 1: plugin name(s). */
    360373                                        'The following required plugin is currently inactive: %1$s.',
    361374                                        'The following required plugins are currently inactive: %1$s.',
    362375                                        'sports-agency'
    363376                                ),
     377                                /* translators: 1: plugin name(s). */
    364378                                'notice_can_activate_recommended' => _n_noop(
    365                                         /* translators: 1: plugin name(s). */
    366379                                        'The following recommended plugin is currently inactive: %1$s.',
    367380                                        'The following recommended plugins are currently inactive: %1$s.',
    … …  
    445458                                add_action( 'switch_theme', array( $this, 'force_deactivation' ) );
    446459                        }
     460
     461                        // Add CSS for the TGMPA admin page.
     462                        add_action( 'admin_head', array( $this, 'admin_css' ) );
     463                }
     464
     465                /**
     466                 * Load translations.
     467                 *
     468                 * @since 2.6.0
     469                 *
     470                 * (@internal Uses `load_theme_textdomain()` rather than `load_plugin_textdomain()` to
     471                 * get round the different ways of handling the path and deprecated notices being thrown
     472                 * and such. For plugins, the actual file name will be corrected by a filter.}}
     473                 *
     474                 * {@internal IMPORTANT! If this function changes, review the regex in the custom TGMPA
     475                 * generator on the website.}}
     476                 */
     477                public function load_textdomain() {
     478                        if ( is_textdomain_loaded( 'sports-agency' ) ) {
     479                                return;
     480                        }
     481
     482                        if ( false !== strpos( __FILE__, WP_PLUGIN_DIR ) || false !== strpos( __FILE__, WPMU_PLUGIN_DIR ) ) {
     483                                // Plugin, we'll need to adjust the file name.
     484                                add_action( 'load_textdomain_mofile', array( $this, 'correct_plugin_mofile' ), 10, 2 );
     485                                load_theme_textdomain( 'sports-agency', dirname( __FILE__ ) . '/languages' );
     486                                remove_action( 'load_textdomain_mofile', array( $this, 'correct_plugin_mofile' ), 10 );
     487                        } else {
     488                                load_theme_textdomain( 'sports-agency', dirname( __FILE__ ) . '/languages' );
     489                        }
     490                }
     491
     492                /**
     493                 * Correct the .mo file name for (must-use) plugins.
     494                 *
     495                 * Themese use `/path/{locale}.mo` while plugins use `/path/{text-domain}-{locale}.mo`.
     496                 *
     497                 * {@internal IMPORTANT! If this function changes, review the regex in the custom TGMPA
     498                 * generator on the website.}}
     499                 *
     500                 * @since 2.6.0
     501                 *
     502                 * @param string $mofile Full path to the target mofile.
     503                 * @param string $domain The domain for which a language file is being loaded.
     504                 * @return string $mofile
     505                 */
     506                public function correct_plugin_mofile( $mofile, $domain ) {
     507                        // Exit early if not our domain (just in case).
     508                        if ( 'sports-agency' !== $domain ) {
     509                                return $mofile;
     510                        }
     511                        return preg_replace( '`/([a-z]{2}_[A-Z]{2}.mo)$`', '/tgmpa-$1', $mofile );
     512                }
     513
     514                /**
     515                 * Potentially overload the fall-back translation file for the current language.
     516                 *
     517                 * WP, by default since WP 3.7, will load a local translation first and if none
     518                 * can be found, will try and find a translation in the /wp-content/languages/ directory.
     519                 * As this library is theme/plugin agnostic, translation files for TGMPA can exist both
     520                 * in the WP_LANG_DIR /plugins/ subdirectory as well as in the /themes/ subdirectory.
     521                 *
     522                 * This method makes sure both directories are checked.
     523                 *
     524                 * {@internal IMPORTANT! If this function changes, review the regex in the custom TGMPA
     525                 * generator on the website.}}
     526                 *
     527                 * @since 2.6.0
     528                 *
     529                 * @param string $mofile Full path to the target mofile.
     530                 * @param string $domain The domain for which a language file is being loaded.
     531                 * @return string $mofile
     532                 */
     533                public function overload_textdomain_mofile( $mofile, $domain ) {
     534                        // Exit early if not our domain, not a WP_LANG_DIR load or if the file exists and is readable.
     535                        if ( 'sports-agency' !== $domain || false === strpos( $mofile, WP_LANG_DIR ) || @is_readable( $mofile ) ) {
     536                                return $mofile;
     537                        }
     538
     539                        // Current fallback file is not valid, let's try the alternative option.
     540                        if ( false !== strpos( $mofile, '/themes/' ) ) {
     541                                return str_replace( '/themes/', '/plugins/', $mofile );
     542                        } elseif ( false !== strpos( $mofile, '/plugins/' ) ) {
     543                                return str_replace( '/plugins/', '/themes/', $mofile );
     544                        } else {
     545                                return $mofile;
     546                        }
    447547                }
    448548
    … …  
    556656
    557657                                global $tab, $body_id;
     658                                // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- WP requirement.
    558659                                $body_id = 'plugin-information';
    559                                 // @codingStandardsIgnoreStart
    560                                 $tab     = 'plugin-information';
    561                                 // @codingStandardsIgnoreEnd
     660
     661                                // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited -- Overriding the WP global is the point.
     662                                $tab = 'plugin-information';
    562663
    563664                                install_plugin_information();
    … …  
    631732                 */
    632733                protected function add_admin_menu( array $args ) {
    633                         $this->page_hook = add_theme_page( $args['page_title'], $args['menu_title'], $args['capability'], $args['menu_slug'], $args['function'] );
     734                        if ( has_filter( 'tgmpa_admin_menu_use_add_theme_page' ) ) {
     735                                _deprecated_function( 'The "tgmpa_admin_menu_use_add_theme_page" filter', '2.5.0', esc_html__( 'Set the parent_slug config variable instead.', 'sports-agency' ) );
     736                        }
     737
     738                        if ( 'themes.php' === $this->parent_slug ) {
     739                                $this->page_hook = call_user_func( 'add_theme_page', $args['page_title'], $args['menu_title'], $args['capability'], $args['menu_slug'], $args['function'] );
     740                        } else {
     741                                $this->page_hook = call_user_func( 'add_submenu_page', $args['parent_slug'], $args['page_title'], $args['menu_title'], $args['capability'], $args['menu_slug'], $args['function'] );
     742                        }
    634743                }
    635744
    … …  
    647756                public function install_plugins_page() {
    648757                        // Store new instance of plugin table in object.
    649                         $plugin_table = new TGMPA_List_Table;
     758                        $plugin_table = new TGMPA_List_Table();
    650759
    651760                        // Return early if processing a plugin installation action.
    … …  
    735844                                $method = ''; // Leave blank so WP_Filesystem can populate it as necessary.
    736845
    737                                 if ( false === ( $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, array() ) ) ) {
     846                                $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, array() );
     847                                if ( false === $creds ) {
    738848                                        return true;
    739849                                }
    … …  
    792902                                if ( 'update' === $install_type ) {
    793903                                        // Inject our info into the update transient.
    794                                         $to_inject                    = array( $slug => $this->plugins[ $slug ] );
     904                                        $to_inject                    = array(
     905                                                $slug => $this->plugins[ $slug ],
     906                                        );
    795907                                        $to_inject[ $slug ]['source'] = $source;
    796908                                        $this->inject_update_info( $to_inject );
    … …  
    819931                                // Display message based on if all plugins are now active or not.
    820932                                if ( $this->is_tgmpa_complete() ) {
    821                                         echo '<p>', sprintf( esc_html( $this->strings['complete'] ), '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html__( 'Return to the Dashboard', 'sports-agency' ) . '</a>' ), '</p>';
     933                                        echo '<p>', sprintf( esc_html( $this->strings['complete'] ), '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html( $this->strings['dashboard'] ) . '</a>' ), '</p>';
    822934                                        echo '<style type="text/css">#adminmenu .wp-submenu li.current { display: none !important; }</style>';
    823935                                } else {
    … …  
    849961
    850962                        if ( ! is_object( $repo_updates ) ) {
    851                                 $repo_updates = new stdClass;
     963                                $repo_updates = new stdClass();
    852964                        }
    853965
    … …  
    856968
    857969                                if ( empty( $repo_updates->response[ $file_path ] ) ) {
    858                                         $repo_updates->response[ $file_path ] = new stdClass;
     970                                        $repo_updates->response[ $file_path ] = new stdClass();
    859971                                }
    860972
    … …  
    9261038                                                return trailingslashit( $to_path );
    9271039                                        } else {
    928                                                 return new WP_Error( 'rename_failed', esc_html__( 'The remote plugin package does not contain a folder with the desired slug and renaming did not work.', 'sports-agency' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'sports-agency' ), array( 'found' => $subdir_name, 'expected' => $desired_slug ) );
     1040                                                return new WP_Error(
     1041                                                        'rename_failed',
     1042                                                        esc_html__( 'The remote plugin package does not contain a folder with the desired slug and renaming did not work.', 'sports-agency' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'sports-agency' ),
     1043                                                        array(
     1044                                                                'found'    => $subdir_name,
     1045                                                                'expected' => $desired_slug,
     1046                                                        )
     1047                                                );
    9291048                                        }
    9301049                                } elseif ( empty( $subdir_name ) ) {
    931                                         return new WP_Error( 'packaged_wrong', esc_html__( 'The remote plugin package consists of more than one file, but the files are not packaged in a folder.', 'sports-agency' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'sports-agency' ), array( 'found' => $subdir_name, 'expected' => $desired_slug ) );
     1050                                        return new WP_Error(
     1051                                                'packaged_wrong',
     1052                                                esc_html__( 'The remote plugin package consists of more than one file, but the files are not packaged in a folder.', 'sports-agency' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'sports-agency' ),
     1053                                                array(
     1054                                                        'found'    => $subdir_name,
     1055                                                        'expected' => $desired_slug,
     1056                                                )
     1057                                        );
    9321058                                }
    9331059                        }
    … …  
    9601086                                                // Make sure message doesn't display again if bulk activation is performed
    9611087                                                // immediately after a single activation.
    962                                                 if ( ! isset( $_POST['action'] ) ) { // WPCS: CSRF OK.
     1088                                                // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Not using the superglobal.
     1089                                                if ( ! isset( $_POST['action'] ) ) {
    9631090                                                        echo '<div id="message" class="updated"><p>', esc_html( $this->strings['activated_successfully'] ), ' <strong>', esc_html( $this->plugins[ $slug ]['name'] ), '.</strong></p></div>';
    9641091                                                }
    … …  
    9811108                                        // Make sure message doesn't display again if bulk activation is performed
    9821109                                        // immediately after a single activation.
    983                                         if ( ! isset( $_POST['action'] ) ) { // WPCS: CSRF OK.
     1110                                        // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Not using the superglobal.
     1111                                        if ( ! isset( $_POST['action'] ) ) {
    9841112                                                echo '<div id="message" class="error"><p>',
    9851113                                                        sprintf(
    … …  
    11311259
    11321260                                // Register the nag messages and prepare them to be processed.
    1133                                 add_settings_error( 'tgmpa', 'tgmpa', $rendered, $this->get_admin_notice_class() );
     1261                                add_settings_error( 'sports-agency', 'sports-agency', $rendered, $this->get_admin_notice_class() );
    11341262                        }
    11351263
    … …  
    12311359                        global $wp_settings_errors;
    12321360
    1233                         settings_errors( 'tgmpa' );
     1361                        settings_errors( 'sports-agency' );
    12341362
    12351363                        foreach ( (array) $wp_settings_errors as $key => $details ) {
    1236                                 if ( 'tgmpa' === $details['setting'] ) {
     1364                                if ( 'sports-agency' === $details['setting'] ) {
    12371365                                        unset( $wp_settings_errors[ $key ] );
    12381366                                        break;
    … …  
    12761404
    12771405                        $defaults = array(
    1278                                 'name'               => '',      // String
    1279                                 'slug'               => '',      // String
    1280                                 'source'             => 'repo',  // String
    1281                                 'required'           => false,   // Boolean
    1282                                 'version'            => '',      // String
    1283                                 'force_activation'   => false,   // Boolean
    1284                                 'force_deactivation' => false,   // Boolean
    1285                                 'external_url'       => '',      // String
    1286                                 'is_callable'        => '',      // String|Array.
     1406                                'name'               => '',      // String.
     1407                                'slug'               => '',      // String.
     1408                                'source'             => 'repo',  // String.
     1409                                'required'           => false,   // Boolean.
     1410                                'version'            => '',      // String.
     1411                                'force_activation'   => false,   // Boolean.
     1412                                'force_deactivation' => false,   // Boolean.
     1413                                'external_url'       => '',      // String.
     1414                                'is_callable'        => '',      // String or array.
    12871415                        );
    12881416
    … …  
    15501678                                }
    15511679
    1552                                 $response = plugins_api( 'plugin_information', array( 'slug' => $slug, 'fields' => array( 'sections' => false ) ) );
     1680                                $response = plugins_api(
     1681                                        'plugin_information',
     1682                                        array(
     1683                                                'slug'   => $slug,
     1684                                                'fields' => array(
     1685                                                        'sections' => false,
     1686                                                ),
     1687                                        )
     1688                                );
    15531689
    15541690                                $api[ $slug ] = false;
    … …  
    16331769                                // Core update screen.
    16341770                                return true;
    1635                         } elseif ( 'plugins' === $screen->base && ! empty( $_POST['action'] ) ) { // WPCS: CSRF ok.
     1771                        } elseif ( 'plugins' === $screen->base && ! empty( $_POST['action'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing
    16361772                                // Plugins bulk update screen.
    16371773                                return true;
    1638                         } elseif ( 'update' === $screen->base && ! empty( $_POST['action'] ) ) { // WPCS: CSRF ok.
     1774                        } elseif ( 'update' === $screen->base && ! empty( $_POST['action'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing
    16391775                                // Individual updates (ajax call).
    16401776                                return true;
    … …  
    19822118
    19832119                /**
     2120                 * Adds CSS to admin head.
     2121                 *
     2122                 * @since 2.6.2
     2123                 */
     2124                public function admin_css() {
     2125                        if ( ! $this->is_tgmpa_page() ) {
     2126                                return;
     2127                        }
     2128
     2129                        echo '
     2130                        <style>
     2131                        #tgmpa-plugins .tgmpa-type-required > th {
     2132                                border-left: 3px solid #dc3232;
     2133                        }
     2134                        </style>';
     2135                }
     2136
     2137                /**
    19842138                 * Returns the singleton instance of the class.
    19852139                 *
    … …  
    20252179         * @param array $config  Optional. An array of configuration values.
    20262180         */
    2027         function sports_agency_tgmpa( $plugins, $config = array() ) {
     2181        function tgmpa( $plugins, $config = array() ) {
    20282182                $instance = call_user_func( array( get_class( $GLOBALS['tgmpa'] ), 'get_instance' ) );
    20292183
    … …  
    24782632                                $color = '';
    24792633                                if ( ! empty( $item['minimum_version'] ) && $this->tgmpa->does_plugin_require_update( $item['slug'] ) ) {
    2480                                         $color = ' color: #479F49; font-weight: bold;';
     2634                                        $color = ' color: #ff0000; font-weight: bold;';
    24812635                                }
    24822636
    … …  
    25252679                 */
    25262680                public function no_items() {
    2527                         echo esc_html__( 'No plugins to install, update or activate.', 'sports-agency' ) . ' <a href="' . esc_url( self_admin_url() ) . '"> ' . esc_html__( 'Return to the Dashboard', 'sports-agency' ) . '</a>';
     2681                        echo esc_html__( 'No plugins to install, update or activate.', 'sports-agency' ) . ' <a href="' . esc_url( self_admin_url() ) . '"> ' . esc_html( $this->tgmpa->strings['dashboard'] ) . '</a>';
    25282682                        echo '<style type="text/css">#adminmenu .wp-submenu li.current { display: none !important; }</style>';
    25292683                }
    … …  
    26432797                 */
    26442798                public function single_row( $item ) {
    2645                         parent::single_row( $item );
     2799                        echo '<tr class="' . esc_attr( 'tgmpa-type-' . strtolower( $item['type'] ) ) . '">';
     2800                        $this->single_row_columns( $item );
     2801                        echo '</tr>';
    26462802
    26472803                        /**
    … …  
    26882844                 * @since 2.5.0
    26892845                 *
    2690                  * @param string $which 'top' or 'bottom' table navigation.
     2846                 * @param string $which Either 'top' or 'bottom' table navigation.
    26912847                 */
    26922848                public function extra_tablenav( $which ) {
    … …  
    28142970                                $fields = array_keys( $_POST ); // Extra fields to pass to WP_Filesystem.
    28152971
    2816                                 if ( false === ( $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, $fields ) ) ) {
     2972                                $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, $fields );
     2973                                if ( false === $creds ) {
    28172974                                        return true; // Stop the normal page form from displaying, credential request form will be shown.
    28182975                                }
    … …  
    29423099                                        $imploded     = empty( $plugin_names ) ? $last_plugin : ( implode( ', ', $plugin_names ) . ' ' . esc_html_x( 'and', 'plugin A *and* plugin B', 'sports-agency' ) . ' ' . $last_plugin );
    29433100
    2944                                         printf( // WPCS: xss ok.
     3101                                        printf(
    29453102                                                '<div id="message" class="updated"><p>%1$s %2$s.</p></div>',
    29463103                                                esc_html( _n( 'The following plugin was activated successfully:', 'The following plugins were activated successfully:', $count, 'sports-agency' ) ),
     3104                                                // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Pre-escaped via wrap_in_strong() method above.
    29473105                                                $imploded
    29483106                                        );
    … …  
    32893447                                                                break;
    32903448                                                        }
    3291                                                 } //end foreach $plugins
     3449                                                }
    32923450
    32933451                                                $this->maintenance_mode( false );
    … …  
    33093467                                                 * }
    33103468                                                 */
    3311                                                 do_action( 'upgrader_process_complete', $this, array(
    3312                                                         'action'  => 'install', // [TGMPA + ] adjusted.
    3313                                                         'type'    => 'plugin',
    3314                                                         'bulk'    => true,
    3315                                                         'plugins' => $plugins,
    3316                                                 ) );
     3469                                                do_action(
     3470                                                        // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedHooknameFound -- Using WP core hook.
     3471                                                        'upgrader_process_complete',
     3472                                                        $this,
     3473                                                        array(
     3474                                                                'action'  => 'install', // [TGMPA + ] adjusted.
     3475                                                                'type'    => 'plugin',
     3476                                                                'bulk'    => true,
     3477                                                                'plugins' => $plugins,
     3478                                                        )
     3479                                                );
    33173480
    33183481                                                $this->skin->bulk_footer();
    … …  
    35013664                                                                $this->upgrader->strings['skin_upgrade_start'] = __( 'The installation and activation process is starting. This process may take a while on some hosts, so please be patient.', 'sports-agency' );
    35023665                                                                /* translators: 1: plugin name. */
    3503                                                                 $this->upgrader->strings['skin_update_successful'] = __( '%1$s installed and activated successfully.', 'sports-agency' ) . ' <a href="#" class="hide-if-no-js" onclick="%2$s"><span>' . esc_html__( 'Show Details', 'sports-agency' ) . '</span><span class="hidden">' . esc_html__( 'Hide Details', 'sports-agency' ) . '</span>.</a>';
     3666                                                                $this->upgrader->strings['skin_update_successful'] = __( '%1$s installed and activated successfully.', 'sports-agency' );
    35043667                                                                $this->upgrader->strings['skin_upgrade_end']       = __( 'All installations and activations have been completed.', 'sports-agency' );
    35053668                                                                /* translators: 1: plugin name, 2: action number 3: total number of actions. */
    … …  
    35093672                                                                $this->upgrader->strings['skin_upgrade_start'] = __( 'The installation process is starting. This process may take a while on some hosts, so please be patient.', 'sports-agency' );
    35103673                                                                /* translators: 1: plugin name. */
    3511                                                                 $this->upgrader->strings['skin_update_successful'] = esc_html__( '%1$s installed successfully.', 'sports-agency' ) . ' <a href="#" class="hide-if-no-js" onclick="%2$s"><span>' . esc_html__( 'Show Details', 'sports-agency' ) . '</span><span class="hidden">' . esc_html__( 'Hide Details', 'sports-agency' ) . '</span>.</a>';
     3674                                                                $this->upgrader->strings['skin_update_successful'] = __( '%1$s installed successfully.', 'sports-agency' );
    35123675                                                                $this->upgrader->strings['skin_upgrade_end']       = __( 'All installations have been completed.', 'sports-agency' );
    35133676                                                                /* translators: 1: plugin name, 2: action number 3: total number of actions. */
    35143677                                                                $this->upgrader->strings['skin_before_update_header'] = __( 'Installing Plugin %1$s (%2$d/%3$d)', 'sports-agency' );
     3678                                                        }
     3679
     3680                                                        // Add "read more" link only for WP < 4.8.
     3681                                                        if ( version_compare( $this->tgmpa->wp_version, '4.8', '<' ) ) {
     3682                                                                $this->upgrader->strings['skin_update_successful'] .= ' <a href="#" class="hide-if-no-js" onclick="%2$s"><span>' . esc_html__( 'Show Details', 'sports-agency' ) . '</span><span class="hidden">' . esc_html__( 'Hide Details', 'sports-agency' ) . '</span>.</a>';
    35153683                                                        }
    35163684                                                }
    … …  
    35723740                                                        $update_actions['dashboard'] = sprintf(
    35733741                                                                esc_html( $this->tgmpa->strings['complete'] ),
    3574                                                                 '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html__( 'Return to the Dashboard', 'sports-agency' ) . '</a>'
     3742                                                                '<a href="' . esc_url( self_admin_url() ) . '">' . esc_html( $this->tgmpa->strings['dashboard'] ) . '</a>'
    35753743                                                        );
    35763744                                                } else {
    … …  
    37153883                 */
    37163884                protected static function emulate_filter_bool( $value ) {
    3717                         // @codingStandardsIgnoreStart
     3885                        // phpcs:disable WordPress.Arrays.ArrayDeclarationSpacing.ArrayItemNoNewLine
    37183886                        static $true  = array(
    37193887                                '1',
    … …  
    37303898                                'off', 'Off', 'OFF',
    37313899                        );
    3732                         // @codingStandardsIgnoreEnd
     3900                        // phpcs:enable
    37333901
    37343902                        if ( is_bool( $value ) ) {
    … …  
    37523920                }
    37533921        } // End of class TGMPA_Utils
    3754 } // End of class_exists wrapper
     3922}
  • sports-agency/0.1.4/includes/tgm/tgm.php

    r278457 r313061  
    4646        );
    4747        $config = array();
    48         sports_agency_tgmpa( $plugins, $config );
     48        tgmpa( $plugins, $config );
    4949}
    5050add_action( 'tgmpa_register', 'sports_agency_register_recommended_plugins' );
  • sports-agency/0.1.4/readme.txt

    r307781 r313061  
    22Contributors: wpelemento
    33Requires at least: 5.0
    4 Stable tag: 0.1.2
     4Stable tag: 0.1.4
    55Requires PHP: 7.2
    66Tested up to: 6.9
    … …  
    2525
    2626Font Awesome Free 6.5.2 by @fontawesome - https://fontawesome.com
    27  * License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
     27* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
    2828
    2929Webfonts Loader
    … …  
    110110== Changelog ==
    111111
     112= February-5-2026 :: 0.1.4
     113
     114* Added hover effect on product featured image.
     115* Added animation on single post.
     116* Added animation on related post.
     117* Hover color on getstarted button.
     118
     119= January-12-2026 :: 0.1.3
     120
     121* Updated rtl.css file.
     122* Added hover effect on single post featured image.
     123* Resolve css error.
     124* Added menu in demo import.
     125* Fetching products in shop page.       
     126* Resolve tgm plugin error.
     127
    112128= January-1-2026 :: 0.1.2
    113129
  • sports-agency/0.1.4/rtl.css

    r288447 r313061  
    18231823 /* Wide Block  */
    18241824 
    1825  .alignwide {
     1825.alignwide {
    18261826  margin-right  : -60px;
    18271827  margin-left : -60px;
    … …  
    18321832  max-width    : 100vw;
    18331833}
     1834
     1835/* ===============================================
     1836   Sticky Copyright
     1837============================================= */
     1838
     1839.sticky-copyright.footer-copyright{
     1840  position: fixed;
     1841  bottom:0;
     1842  right:0;
     1843  width: 100%;
     1844  z-index: 999;
     1845  transition: bottom 0.4s;
     1846  box-shadow: 0px 0px 8px #000000;
     1847}
     1848.close-sticky {
     1849  position: static;
     1850}
     1851
     1852/* ===============================================
     1853   Sticky Sidebar
     1854============================================= */
     1855
     1856.sidebar-sticky {
     1857  position: sticky;
     1858  top: 100px;
     1859  z-index: 999;
     1860}
  • sports-agency/0.1.4/style.css

    r307781 r313061  
    55Theme URI: https://www.wpelemento.com/products/sports-agency
    66Author URI: https://www.wpelemento.com/
    7 Version: 0.1.2
     7Version: 0.1.4
    88Requires PHP: 7.2
    99Tested up to: 6.9
  • sports-agency/0.1.4/template-parts/content-post.php

    r278457 r313061  
    1717<div id="post-<?php the_ID(); ?>" <?php post_class('post-single mb-4'); ?>>
    1818  <?php if ( has_post_thumbnail() && get_theme_mod( 'sports_agency_single_post_featured_image',true) ) { ?>
    19     <div class="post-thumbnail post-img">
     19    <div class="post-thumbnail post-img <?php echo esc_attr( get_theme_mod(' sports_agency_enable_post_animation', true) ? 'zoomInUp wow' : '' ); ?>">
    2020      <?php the_post_thumbnail(''); ?>
    2121    </div>
  • sports-agency/0.1.4/template-parts/related-posts.php

    r278457 r313061  
    2222
    2323if ( $sports_agency_related_posts->have_posts() ) : ?>
    24     <div class="related-post">
     24    <div class="related-post <?php echo esc_attr( get_theme_mod('sports_agency_enable_post_animation', true) ? 'zoomInUp wow' : '' ); ?>">
    2525        <h3><?php echo esc_html__('Related Post' ,'sports-agency' );?></h3>
    2626        <div class="row">
Note: See TracChangeset for help on using the changeset viewer.