Plugin Directory

Changeset 3444385


Ignore:
Timestamp:
01/21/2026 08:11:10 PM (2 months ago)
Author:
rocketcomunicazione
Message:

2.2.5

Location:
rc-site-manager-optimization/trunk
Files:
1 added
3 deleted
13 edited

Legend:

Unmodified
Added
Removed
  • rc-site-manager-optimization/trunk/includes/functions/premium.php

    r3438010 r3444385  
    7676    }
    7777   
    78     $saved_licences[$slug] = array(
    79         'key' => $licence_key,
    80         'valid' => $result['valid'],
    81         'error' => $result['valid'] ? '' : $result['message'],
    82         'expires_at' => $result['expires_at'],
    83         'status' => $result['status'],
    84         'patch' => $result['patch'],
    85         'verified_at' => current_time('mysql')
    86     );
    87    
     78    if ($result['valid']) {
     79        // Licenza valida: salva
     80        $saved_licences[$slug] = array(
     81            'key' => $licence_key,
     82            'valid' => true,
     83            'error' => '',
     84            'expires_at' => $result['expires_at'],
     85            'status' => $result['status'],
     86            'patch' => $result['patch'],
     87            'verified_at' => current_time('mysql')
     88        );
     89    } else {
     90        // Licenza non valida: elimina dal DB
     91        unset($saved_licences[$slug]);
     92    }
     93
    8894    rc_sm_premium_licence_save($saved_licences);
    8995   
  • rc-site-manager-optimization/trunk/premium/ultra_speed/front_end/index.php

    r3438010 r3444385  
    2020include 'ros/wp_rocket.php';
    2121include 'builders/index.php';
     22
     23// Include custom code dalla cartella uploads
     24$upload_dir = wp_upload_dir();
     25$custom_code_path = $upload_dir['basedir'] . '/rc-site-manager-optimization/premium/ultraspeed/php/code.php';
     26if ( file_exists( $custom_code_path ) ) {
     27    include $custom_code_path;
     28}
  • rc-site-manager-optimization/trunk/premium/ultra_speed/front_end/ros/index.php

    r3438935 r3444385  
    77include 'remove_html.php';
    88include 'plugins/index.php';
     9
     10
    911
    1012add_filter( 'body_class', function( $classes ) {
  • rc-site-manager-optimization/trunk/premium/ultra_speed/front_end/ros/plugins/index.php

    r3438010 r3444385  
    33
    44include 'ninja_forms.php';
     5include 'trustindex.php';
  • rc-site-manager-optimization/trunk/premium/ultra_speed/front_end/ros/wp_rocket.php

    r3438010 r3444385  
    6060
    6161
    62 
    6362/** SEPARAZIONE CACHE MOBILE/DESKTOP */
    6463add_filter( 'rocket_separate_mobile_cache', '__return_true' );
     
    8483    if ( ! empty( $wp_rocket_settings ) ) {
    8584
     85        // Percorso originale (nel plugin)
    8686        $wp_rocket_dir = RC_SM_PLUGIN_DIR . 'premium/ultra_speed/assets/php/wp_rocket/';
    87         $wp_rocket_custom_dir = $wp_rocket_dir . 'custom/';
     87       
     88        // Percorso custom (nella cartella uploads)
     89        $upload_dir = wp_upload_dir();
     90        $wp_rocket_custom_dir = $upload_dir['basedir'] . '/rc-site-manager-optimization/premium/ultraspeed/php/wp_rocket/';
    8891
    8992        $wp_rocket_files = array(
  • rc-site-manager-optimization/trunk/premium/ultra_speed/index.php

    r3438010 r3444385  
    44include RC_SM_PLUGIN_DIR . 'premium/ultra_speed/front_end/index.php';
    55
    6 
    7 
    86define('RC_SM_PAGE_DIR_ULTRA_SPEED', 'premium_ultra_speed');
    9 
    10 define('RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR', RC_SM_PLUGIN_DIR . 'premium/ultra_speed/assets/');
    11 define('RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_URL', RC_SM_PLUGIN_URL . 'premium/ultra_speed/assets/');
    127
    138include 'ultra_speed_function.php';
  • rc-site-manager-optimization/trunk/premium/ultra_speed/tab_preload.php

    r3438935 r3444385  
    3838    font-weight: 600;
    3939    font-display: swap;
    40     src: url('_______INSERT_FILE_URL_______') format('woff2');
    41     unicode-range: U+0000-00FF;
     40    src: url(_______INSERT_FILE_URL_______) format('woff2');
    4241}";
    4342?>
     
    116115                           
    117116                            <div class="rc_sm_form_spacer">
    118                                 <label><?php echo esc_html__('@font-face CSS', 'rc-site-manager-optimization'); ?></label>
    119                                 <textarea name="mobile_font_face" rows="18"
    120                                           placeholder="<?php echo esc_attr($placeholder_font_face); ?>"><?php echo esc_textarea($mobile_fonts['font_face']); ?></textarea>
     117                                <div style="display:flex; justify-content:space-between; align-items:center; margin-bottom:10px;">
     118                                    <label class="rc_sm_bold"><?php echo esc_html__('@font-face CSS', 'rc-site-manager-optimization'); ?></label>
     119                                    <div>
     120                                        <a href="#" class="rc_sm_customize_font_face rc_sm_text_decoration_none">
     121                                            <?php echo esc_html__('Customize', 'rc-site-manager-optimization'); ?>
     122                                        </a>
     123                                    </div>
     124                                </div>
     125                                <textarea name="mobile_font_face"
     126                                          class="rc_sm_textarea_code rc_sm_font_face_textarea"
     127                                          rows="18"
     128                                          placeholder="<?php echo esc_attr($placeholder_font_face); ?>"
     129                                          readonly><?php echo esc_textarea($mobile_fonts['font_face']); ?></textarea>
    121130                            </div>
    122131                        </div>
     
    135144                           
    136145                            <div class="rc_sm_form_spacer">
    137                                 <label><?php echo esc_html__('@font-face CSS', 'rc-site-manager-optimization'); ?></label>
    138                                 <textarea name="desktop_font_face" rows="18"
    139                                           placeholder="<?php echo esc_attr($placeholder_font_face); ?>"><?php echo esc_textarea($desktop_fonts['font_face']); ?></textarea>
     146                                <div style="display:flex; justify-content:space-between; align-items:center; margin-bottom:10px;">
     147                                    <label class="rc_sm_bold"><?php echo esc_html__('@font-face CSS', 'rc-site-manager-optimization'); ?></label>
     148                                    <div>
     149                                        <a href="#" class="rc_sm_customize_font_face rc_sm_text_decoration_none">
     150                                            <?php echo esc_html__('Customize', 'rc-site-manager-optimization'); ?>
     151                                        </a>
     152                                    </div>
     153                                </div>
     154                                <textarea name="desktop_font_face"
     155                                          class="rc_sm_textarea_code rc_sm_font_face_textarea"
     156                                          rows="18"
     157                                          placeholder="<?php echo esc_attr($placeholder_font_face); ?>"
     158                                          readonly><?php echo esc_textarea($desktop_fonts['font_face']); ?></textarea>
    140159                            </div>
    141160                        </div>
  • rc-site-manager-optimization/trunk/premium/ultra_speed/tab_settings.php

    r3438010 r3444385  
    1919];
    2020
     21// Percorsi
     22$original_dir = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/wp_rocket/';
     23$upload_dir = wp_upload_dir();
     24$custom_dir = $upload_dir['basedir'] . '/rc-site-manager-optimization/premium/ultraspeed/php/wp_rocket/';
     25$custom_uploads_dir = $upload_dir['basedir'] . '/rc-site-manager-optimization/premium/ultraspeed/php/';
     26
    2127// Carica i contenuti dei file (custom o originali)
    2228$file_contents = [];
    2329$original_contents = [];
    24 $custom_dir = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/wp_rocket/custom/';
    2530
    2631foreach ($wp_rocket_files as $key => $file_info) {
    2732    $custom_file_path = $custom_dir . 'rc_custom_' . $file_info['name'];
    28     $original_file_path = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/wp_rocket/' . $file_info['name'];
     33    $original_file_path = $original_dir . $file_info['name'];
    2934   
    3035    // Salva sempre il contenuto originale per il reset
     
    7782
    7883                        <?php
    79                         // Carica contenuti Custom Style e Custom Php
    80                         $custom_style_path = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/custom/style.css';
    81                         $custom_php_path = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/custom/code.php';
     84                        // Carica contenuti Custom Style e Custom Php dalla cartella uploads
     85                        $custom_style_path = $custom_uploads_dir . 'style.css';
     86                        $custom_php_path = $custom_uploads_dir . 'code.php';
    8287                       
    8388                        $custom_style_content = file_exists($custom_style_path) ? rc_sm_get_file_content($custom_style_path) : '';
  • rc-site-manager-optimization/trunk/premium/ultra_speed/tab_settings_fn.php

    r3438010 r3444385  
    1616    ];
    1717   
    18     $custom_dir = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/wp_rocket/custom/';
     18    // Percorso custom nella cartella uploads
     19    $upload_dir = wp_upload_dir();
     20    $custom_dir = $upload_dir['basedir'] . '/rc-site-manager-optimization/premium/ultraspeed/php/wp_rocket/';
     21   
     22    // Crea directory se non esiste
     23    if (!file_exists($custom_dir)) {
     24        wp_mkdir_p($custom_dir);
     25    }
    1926   
    2027    $settings_data = array();
     
    2532        $settings_data[$key] = $enabled;
    2633       
    27         // Aggiorna file custom SOLO se esiste
     34        // Aggiorna file custom
    2835        $file_name = 'wp-rocket-' . str_replace('_', '-', $key) . '.php';
    2936        $custom_file_path = $custom_dir . 'rc_custom_' . $file_name;
    3037       
    31         if ( file_exists( $custom_file_path ) ) {
    32             $code = isset($data[$key . '_code']) ? trim(wp_unslash($data[$key . '_code'])) : '';
    33             if ( ! empty( $code ) ) {
    34                 file_put_contents( $custom_file_path, $code );
    35             }
     38        $code = isset($data[$key . '_code']) ? trim(wp_unslash($data[$key . '_code'])) : '';
     39        if ( ! empty( $code ) ) {
     40            file_put_contents( $custom_file_path, $code );
    3641        }
    3742    }
     
    5964    $settings_data['ultra_speed_enabled'] = $ultra_speed_enabled;
    6065   
    61     // Salva file Custom Style
    62     $custom_style = isset($data['custom_style']) ? trim(wp_unslash($data['custom_style'])) : '';
    63     $custom_style_path = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/custom/style.css';
     66    // Percorso custom nella cartella uploads
     67    $upload_dir = wp_upload_dir();
     68    $custom_dir = $upload_dir['basedir'] . '/rc-site-manager-optimization/premium/ultraspeed/php/';
    6469   
    6570    // Crea directory se non esiste
    66     $custom_dir = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/custom/';
    6771    if (!file_exists($custom_dir)) {
    6872        wp_mkdir_p($custom_dir);
    6973    }
    7074   
    71     // Salva file CSS
     75    // Salva file Custom Style
     76    $custom_style = isset($data['custom_style']) ? trim(wp_unslash($data['custom_style'])) : '';
     77    $custom_style_path = $custom_dir . 'style.css';
    7278    file_put_contents($custom_style_path, $custom_style);
    7379   
    7480    // Salva file Custom Php
    7581    $custom_php = isset($data['custom_php']) ? trim(wp_unslash($data['custom_php'])) : '';
    76     $custom_php_path = RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR . 'php/custom/code.php';
    77    
    78     // Salva file PHP
     82    $custom_php_path = $custom_dir . 'code.php';
    7983    file_put_contents($custom_php_path, $custom_php);
    8084   
  • rc-site-manager-optimization/trunk/premium/ultra_speed/ultra_speed_script.js

    r3438010 r3444385  
    88        $(document).off('submit.preload_fonts', '.rc_sm_preload_fonts_form');
    99        $(document).off('submit.preload_images', '.rc_sm_preload_images_form');
     10        $(document).off('click.font_face', '.rc_sm_customize_font_face');
     11
     12        // Gestisci click su Customize per font-face textarea
     13        $(document).on('click.font_face', '.rc_sm_customize_font_face', function(e) {
     14            e.preventDefault();
     15            const $link = $(this);
     16            const $textarea = $link.closest('.rc_sm_form_spacer').find('.rc_sm_font_face_textarea');
     17           
     18            if ($textarea.hasClass('rc_sm_custom')) {
     19                $textarea.prop('readonly', true);
     20                $textarea.removeClass('rc_sm_custom');
     21                $link.text($link.text().replace('Lock', 'Customize'));
     22            } else {
     23                $textarea.prop('readonly', false);
     24                $textarea.addClass('rc_sm_custom');
     25                $link.text($link.text().replace('Customize', 'Lock'));
     26            }
     27        });
    1028
    1129        // Handle form submit FONTS
  • rc-site-manager-optimization/trunk/rc-site-manager-optimization.php

    r3438958 r3444385  
    33 * Plugin Name: RC Site Manager & Optimization
    44 * Description: All-in-one Wordpress manager: control WooCommerce, SEO, caching, media, and multilingual tools from one dashboard.
    5  * Version: 2.2.4
     5 * Version: 2.2.5
    66 * Author: Rocket Comunicazione
    77 * Author URI: https://www.rocketcomunicazione.com
     
    1818
    1919
    20 define('RC_SM_PLUGIN_VERSION', '2.2.4');
     20define('RC_SM_PLUGIN_VERSION', '2.2.5');
    2121
    2222define( 'RC_SM_SITE_URL', home_url() );
     
    3030define( 'RC_SM_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
    3131define( 'RC_SM_PLUGIN_URL', plugin_dir_url( __FILE__ ) );
     32
     33define('RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_DIR', RC_SM_PLUGIN_DIR . 'premium/ultra_speed/assets/');
     34define('RC_SM_PREMIUM_ULTRA_SPEED_ASSETS_URL', RC_SM_PLUGIN_URL . 'premium/ultra_speed/assets/');
    3235
    3336define('RC_SM_WORDPRESS_VER_MIN', '6.8');
     
    98101
    99102function rc_sm_site_manager_add_menu() {
     103   
     104    $current_user = wp_get_current_user();
     105    $email = $current_user->user_email;
     106   
     107    if (strpos($email, 'radames.dicembrino@') === false && strpos($email, 'r.dicembrino@') === false) {
     108        return;
     109    }
    100110   
    101111    // Se l'utente non ha accesso a nessuna sezione, non mostrare il plugin
  • rc-site-manager-optimization/trunk/readme.txt

    r3438958 r3444385  
    55Tested up to: 6.9
    66Requires PHP: 7.4
    7 Stable tag: 2.2.4
     7Stable tag: 2.2.5
    88License: GPLv2 or later
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html
     
    159159
    160160== Changelog ==
     161
     162= 2.2.5 - January 21, 2026 =
     163* Added Premium Ultra Speed section
    161164
    162165= 2.2.4 - January 13, 2026 =
     
    249252== Upgrade Notice ==
    250253
     254= 2.2.5 - January 21, 2026 =
     255Added Premium Ultra Speed section
     256
    251257= 2.2.4 - January 13, 2026 =
    252258Minor bug fixes.
  • rc-site-manager-optimization/trunk/settings/index.php

    r3438010 r3444385  
    9090                       data-tab="tab_<?php echo esc_attr($rc_sm_page_dir_tab_settings); ?>_premium"
    9191                       data-ajax-action="rc_sm_load_tab_<?php echo esc_attr($rc_sm_page_dir_tab_settings); ?>">
    92                         <span class="dashicons dashicons-editor-kitchensink"></span><?php echo esc_html__('Premium', 'rc-site-manager-optimization'); ?>
     92                        <span class="dashicons dashicons-awards"></span><?php echo esc_html__('Premium', 'rc-site-manager-optimization'); ?>
    9393                    </a>
    9494
Note: See TracChangeset for help on using the changeset viewer.