Plugin Directory

Changeset 3381323


Ignore:
Timestamp:
10/20/2025 01:20:25 PM (5 months ago)
Author:
clonable
Message:

Version 2.7.2

Location:
clonable
Files:
123 added
11 edited

Legend:

Unmodified
Added
Removed
  • clonable/trunk/clonable-wp.php

    r3378896 r3381323  
    55Description: Official plugin for improving your clones made with Clonable.
    66Plugin URI: https://kb.clonable.net/en/introduction/getting-started/wordpress#de-clonable-plug-in-downloaden
    7 Version: 2.7.1
     7Version: 2.7.2
    88Author: Clonable BV
    99Author URI: https://www.clonable.net
     
    115115
    116116define('CLONABLE_NAME', 'Clonable');
    117 define('CLONABLE_VERSION', '2.7.1');
     117define('CLONABLE_VERSION', '2.7.2');
    118118
    119119if (defined('WP_CLI') && WP_CLI) {
  • clonable/trunk/readme-da_DK.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme-de_DE.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme-es_ES.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme-fr_FR.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme-it_IT.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme-nb_NO.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme-nl_NL.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme-sv_SE.txt

    r3378896 r3381323  
    55Tested up to: 6.8.2
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/readme.txt

    r3378896 r3381323  
    55Tested up to: 6.8.3
    66Requires PHP: 7.2
    7 Stable tag: 2.7.1
     7Stable tag: 2.7.2
    88License: GPL v2 or later
    99
     
    3232
    3333== Changelog ==
     34v2.7.2
     35Improved form handling for subfolders.
     36
    3437v2.7.1
    3538Added IPv6 compatibility
  • clonable/trunk/services/SubfolderService.php

    r3377392 r3381323  
    132132            do_action('clonable_after_page_translation', $request_path);
    133133            exit; // exit current script, otherwise the page gets loaded twice at the bottom of the page
     134        }
     135
     136        if (Functions::str_starts_with($request_path, "/clonable-cgi/")) {
     137            if (Functions::str_starts_with($request_path, "/clonable-cgi/js/")) {
     138                header("Content-type: application/javascript");
     139            } else if (Functions::str_starts_with($request_path, "/clonable-cgi/css/")) {
     140                header("Content-type: text/css");
     141            }
     142            header("Cache-Control: public, max-age=86400");
     143
     144            while(ob_get_level()) {
     145                $success = ob_end_clean();
     146                if (!$success) {
     147                    // break if the output buffer cannot be deleted.
     148                    break;
     149                }
     150            }
     151            exit;
    134152        }
    135153        // Don't need an else or return.
     
    157175        } else {
    158176            return (file_get_contents('php://input') ?? null);
     177        }
     178    }
     179
     180    /**
     181     * Parses the individual
     182     *
     183     * @param $delimiter
     184     * @param $name
     185     * @param $content
     186     * @return string
     187     */
     188    private function build_content_field($delimiter, $name, $content) {
     189        $eol = "\r\n";
     190        if (is_array($content)) {
     191            $sub_data = "";
     192            foreach ($content as $sub_name => $sub_content) {
     193                $sub_data .= $this->build_content_field($delimiter, "{$name}[$sub_name]", $sub_content);
     194            }
     195            return $sub_data;
     196        } else {
     197            return "--" . $delimiter . $eol
     198                . 'Content-Disposition: form-data; name="' . $name . "\"".$eol.$eol
     199                . $content . $eol;
    159200        }
    160201    }
     
    178219        // convert post fields to multipart form-data variant
    179220        foreach ($_POST as $name => $content) {
    180             $data .= "--" . $delimiter . $eol
    181                 . 'Content-Disposition: form-data; name="' . $name . "\"".$eol.$eol
    182                 . $content . $eol;
     221            $data .= $this->build_content_field($delimiter, $name, $content);
    183222        }
    184223
Note: See TracChangeset for help on using the changeset viewer.