Changeset 3393317
- Timestamp:
- 11/11/2025 02:10:01 AM (5 weeks ago)
- Location:
- vk-all-in-one-expansion-unit
- Files:
-
- 28 edited
- 1 copied
-
tags/9.112.2.0 (copied) (copied from vk-all-in-one-expansion-unit/trunk)
-
tags/9.112.2.0/admin/class-veu-metabox.php (modified) (1 diff)
-
tags/9.112.2.0/inc/add_menu_to_block_reuse.php (modified) (1 diff)
-
tags/9.112.2.0/inc/call-to-action/package/block/index.php (modified) (2 diffs)
-
tags/9.112.2.0/inc/call-to-action/package/class-vk-call-to-action.php (modified) (1 diff)
-
tags/9.112.2.0/inc/css-customize/class-veu-metabox-css-customize.php (modified) (1 diff)
-
tags/9.112.2.0/inc/css-customize/css-customize-single.php (modified) (3 diffs)
-
tags/9.112.2.0/inc/promotion-alert/config.php (modified) (1 diff)
-
tags/9.112.2.0/inc/promotion-alert/package/class-veu-promotion-alert-metabox.php (modified) (3 diffs)
-
tags/9.112.2.0/inc/promotion-alert/package/class-veu-promotion-alert.php (modified) (6 diffs)
-
tags/9.112.2.0/inc/wp-title/package/wp-title.php (modified) (1 diff)
-
tags/9.112.2.0/readme.txt (modified) (1 diff)
-
tags/9.112.2.0/vendor/composer/installed.php (modified) (2 diffs)
-
tags/9.112.2.0/veu-packages.php (modified) (2 diffs)
-
tags/9.112.2.0/vkExUnit.php (modified) (1 diff)
-
trunk/admin/class-veu-metabox.php (modified) (1 diff)
-
trunk/inc/add_menu_to_block_reuse.php (modified) (1 diff)
-
trunk/inc/call-to-action/package/block/index.php (modified) (2 diffs)
-
trunk/inc/call-to-action/package/class-vk-call-to-action.php (modified) (1 diff)
-
trunk/inc/css-customize/class-veu-metabox-css-customize.php (modified) (1 diff)
-
trunk/inc/css-customize/css-customize-single.php (modified) (3 diffs)
-
trunk/inc/promotion-alert/config.php (modified) (1 diff)
-
trunk/inc/promotion-alert/package/class-veu-promotion-alert-metabox.php (modified) (3 diffs)
-
trunk/inc/promotion-alert/package/class-veu-promotion-alert.php (modified) (6 diffs)
-
trunk/inc/wp-title/package/wp-title.php (modified) (1 diff)
-
trunk/readme.txt (modified) (1 diff)
-
trunk/vendor/composer/installed.php (modified) (2 diffs)
-
trunk/veu-packages.php (modified) (2 diffs)
-
trunk/vkExUnit.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
vk-all-in-one-expansion-unit/tags/9.112.2.0/admin/class-veu-metabox.php
r3214209 r3393317 172 172 173 173 // nonce を確認し、値が書き換えられていれば、何もしない(CSRF対策) 174 if ( ! wp_verify_nonce( $noncename__value, wp_create_nonce( __FILE__ )) ) {174 if ( ! wp_verify_nonce( $noncename__value, __FILE__ ) ) { 175 175 return $post_id; 176 176 } -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/add_menu_to_block_reuse.php
r3214209 r3393317 11 11 $position = 20; 12 12 $menu_slug = 'edit.php?post_type=wp_block'; 13 $menu_title = __( ' Manage all reusable blocks', 'vk-all-in-one-expansion-unit' );13 $menu_title = __( 'Patterns', 'vk-all-in-one-expansion-unit' ); 14 14 15 15 while ( isset( $menu[ $position ] ) ) { -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/call-to-action/package/block/index.php
r3286716 r3393317 231 231 } 232 232 233 $url = get_post_meta( $cta_id, 'vkExUnit_cta_url', true);233 $url = esc_url( get_post_meta( $cta_id, 'vkExUnit_cta_url', true ) ); 234 234 $text = get_post_meta( $cta_id, 'vkExUnit_cta_text', true ); 235 235 $text = preg_replace( '/\n/', '<br/>', $text ); … … 282 282 283 283 // Display Edit Button. 284 $url = get_edit_post_link( $cta_post->ID);284 $url = esc_url( get_edit_post_link( $cta_post->ID ) ); 285 285 if ( $url ) { 286 286 $content .= '<div class="veu_adminEdit veu_adminEdit_cta"><a href="' . $url . '" class="btn btn-default" target="_blank">' . __( 'Edit CTA', 'vk-all-in-one-expansion-unit' ) . '</a></div>'; -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/call-to-action/package/class-vk-call-to-action.php
r3286716 r3393317 196 196 // カスタムフィールドの保存. 197 197 foreach ( $custom_fields as $custom_field_name => $custom_field_options ) { 198 $data = ''; 198 199 if ( isset( $_POST[ $custom_field_name ] ) ) { 199 if ( ! empty( $custom_field_ name['escape_type'] ) ) {200 if ( is_array( $custom_field_ name['escape_type'] ) ) {200 if ( ! empty( $custom_field_options['escape_type'] ) ) { 201 if ( is_array( $custom_field_options['escape_type'] ) ) { 201 202 // エスケープ処理が複数ある場合 202 203 $data = $_POST[ $custom_field_name ]; 203 foreach ( $custom_field_ name['escape_type'] as $escape ) {204 foreach ( $custom_field_options['escape_type'] as $escape ) { 204 205 $data = call_user_func( $escape, $data ); 205 206 } 206 207 } else { 207 208 // エスケープ処理が一つの場合 208 $data = call_user_func( $custom_field_ name['escape_type'], $_POST[ $custom_field_name ] );209 $data = call_user_func( $custom_field_options['escape_type'], $_POST[ $custom_field_name ] ); 209 210 } 210 211 } else { 212 // エスケープ処理が無い場合 211 213 $data = $_POST[ $custom_field_name ]; 212 214 } -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/css-customize/class-veu-metabox-css-customize.php
r3186987 r3393317 29 29 $form = ''; 30 30 31 $form .= '<textarea name="' . esc_attr( $this->args['cf_name'] ) . '" id="' . esc_attr( $this->args['cf_name'] ) . '" rows="5" cols="30" style="width:100%;">' . wp_kses_post( $cf_value ) . '</textarea>';31 $form .= '<textarea name="' . esc_attr( $this->args['cf_name'] ) . '" id="' . esc_attr( $this->args['cf_name'] ) . '" rows="5" cols="30" style="width:100%;">' . esc_textarea( $cf_value ) . '</textarea>'; 32 32 33 33 return $form; 34 } 35 36 /** 37 * Override parent save to sanitize CSS payloads before persisting. 38 * 39 * @param int $post_id Current post ID. 40 * @return int 41 */ 42 public function save_custom_field( $post_id ) { 43 44 if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { 45 return $post_id; 46 } 47 48 $nonce_key = 'noncename__' . $this->args['cf_name']; 49 $nonce_value = isset( $_POST[ $nonce_key ] ) ? $_POST[ $nonce_key ] : null; 50 51 if ( ! wp_verify_nonce( $nonce_value, __FILE__ ) ) { 52 return $post_id; 53 } 54 55 delete_post_meta( $post_id, $this->args['cf_name'] ); 56 57 if ( empty( $_POST[ $this->args['cf_name'] ] ) ) { 58 return $post_id; 59 } 60 61 $raw_css = wp_unslash( $_POST[ $this->args['cf_name'] ] ); 62 $sanitized_css = veu_sanitize_custom_css_input( $raw_css ); 63 if ( '' !== $sanitized_css ) { 64 add_post_meta( $post_id, $this->args['cf_name'], $sanitized_css ); 65 } 66 67 return $post_id; 34 68 } 35 69 } // class VEU_Metabox_CSS_Customize { -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/css-customize/css-customize-single.php
r3214209 r3393317 8 8 } 9 9 add_action( 'after_setup_theme', 'veu_css_customize_single_load', 11 ); 10 11 if ( ! function_exists( 'veu_sanitize_custom_css_input' ) ) { 12 /** 13 * Basic sanitization for the Custom CSS meta field. 14 * Removes HTML tags while keeping CSS-specific characters intact. 15 * 16 * @param string $css Raw CSS provided by editors. 17 * @return string Sanitized CSS string. 18 */ 19 function veu_sanitize_custom_css_input( $css ) { 20 if ( ! is_string( $css ) ) { 21 return ''; 22 } 23 24 $css = wp_check_invalid_utf8( $css ); 25 $css = html_entity_decode( $css, ENT_QUOTES | ENT_HTML5 ); 26 $css = wp_strip_all_tags( $css, false ); 27 $css = preg_replace( '/<\/?style[^>]*>/i', '', $css ); 28 $css = trim( $css ); 29 30 return $css; 31 } 32 } 10 33 11 34 /** … … 29 52 $css = veu_get_the_custom_css_single( $post ); 30 53 if ( $css ) { 31 // HTMLエンティティをデコードし、HTMLタグとその内容を削除 32 $css = html_entity_decode( $css, ENT_QUOTES | ENT_HTML5 ); 33 echo '<style type="text/css">/* ' . esc_html( veu_get_short_name() ) . ' CSS Customize Single */' . $css . '</style>'; 54 $css = veu_sanitize_custom_css_input( $css ); 55 if ( $css ) { 56 echo '<style type="text/css">/* ' . esc_html( veu_get_short_name() ) . ' CSS Customize Single */' . $css . '</style>'; 57 } 34 58 } 35 59 } … … 40 64 $css_customize = get_post_meta( $post->ID, '_veu_custom_css', true ); 41 65 if ( $css_customize ) { 66 $css_customize = veu_sanitize_custom_css_input( $css_customize ); 42 67 // Delete br 43 68 $css_customize = str_replace( PHP_EOL, '', $css_customize ); -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/promotion-alert/config.php
r3214209 r3393317 1 1 <?php 2 2 /** 3 * VEU Promotion AlertSetting3 * VEU Promotion Disclosure Setting 4 4 */ 5 5 -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/promotion-alert/package/class-veu-promotion-alert-metabox.php
r3214209 r3393317 1 1 <?php 2 2 /** 3 * VEU Metabox Promotion Alert3 * VEU Metabox Promotion Disclosure 4 4 */ 5 5 … … 16 16 'slug' => 'veu_display_promotion_alert', 17 17 'cf_name' => 'veu_display_promotion_alert', 18 'title' => __( 'Promotion AlertSetting', 'vk-all-in-one-expansion-unit' ),18 'title' => __( 'Promotion Disclosure Setting', 'vk-all-in-one-expansion-unit' ), 19 19 'priority' => 1, 20 20 ); … … 37 37 38 38 $form .= '<div class="veu_promotion-alert-meta-fields">'; 39 $form .= '<h4>' . __( 'Promotion AlertSetting', 'vk-all-in-one-expansion-unit' ) . '</h4>';39 $form .= '<h4>' . __( 'Promotion Disclosure Setting', 'vk-all-in-one-expansion-unit' ) . '</h4>'; 40 40 $form .= '<select name="veu_display_promotion_alert">'; 41 41 $form .= '<option value="common" ' . selected( $cf_value, 'common', false ) . '>' . __( 'Apply common settings', 'vk-all-in-one-expansion-unit' ) . '</option>'; -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/promotion-alert/package/class-veu-promotion-alert.php
r3214209 r3393317 1 1 <?php 2 2 /** 3 * VEU Promotion Alert3 * VEU Promotion Disclosure 4 4 */ 5 5 … … 202 202 public static function option_init() { 203 203 vkExUnit_register_setting( 204 __( 'Promotion Alert', 'vk-all-in-one-expansion-unit' ), // tab label.204 __( 'Promotion Disclosure', 'vk-all-in-one-expansion-unit' ), // tab label. 205 205 'vkExUnit_PA', // name attr 206 206 array( __CLASS__, 'sanitize_setting' ), // sanitaise function name … … 271 271 $options = self::get_options(); 272 272 ?> 273 <h3><?php _e( 'Promotion Alert', 'vk-all-in-one-expansion-unit' ); ?></h3>273 <h3><?php _e( 'Promotion Disclosure', 'vk-all-in-one-expansion-unit' ); ?></h3> 274 274 <div id="vkExUnit_PA" class="sectionBox"> 275 275 <P> 276 <?php _e( 'If the article contains advertisements, it\'s necessary to provide a clear notationfor general consumers to recognize.', 'vk-all-in-one-expansion-unit' ); ?>276 <?php _e( 'If the article contains advertisements, it\'s necessary to provide a clear disclosure for general consumers to recognize.', 'vk-all-in-one-expansion-unit' ); ?> 277 277 <br> 278 278 <?php _e( 'By inputting here, you can automatically insert it at the beginning of the article.', 'vk-all-in-one-expansion-unit' ); ?> … … 280 280 <table class="form-table"> 281 281 <tr> 282 <th><?php _e( ' AlertText', 'vk-all-in-one-expansion-unit' ); ?></th>282 <th><?php _e( 'Disclosure Text', 'vk-all-in-one-expansion-unit' ); ?></th> 283 283 <td> 284 284 <p> … … 294 294 </tr> 295 295 <tr> 296 <th><?php _e( 'Custom AlertContent', 'vk-all-in-one-expansion-unit' ); ?></th>296 <th><?php _e( 'Custom Disclosure Content', 'vk-all-in-one-expansion-unit' ); ?></th> 297 297 <td> 298 298 <textarea name="vkExUnit_PA[alert-content]" style="width:100%;" rows="10"><?php echo $options['alert-content']; ?></textarea> 299 299 <ul> 300 <li><?php _e( 'If there is any input in "Custom Alert Content", "Alert Text" will not be displayed and will be overwritten by the content entered in "Custom AlertContent".', 'vk-all-in-one-expansion-unit' ); ?></li>300 <li><?php _e( 'If there is any input in "Custom Disclosure Content", "Disclosure Text" will not be displayed and will be overwritten by the content entered in "Custom Disclosure Content".', 'vk-all-in-one-expansion-unit' ); ?></li> 301 301 <li><?php _e( 'You can insert HTML tags here. This is designed to be used by pasting content created in the Block Editor.', 'vk-all-in-one-expansion-unit' ); ?></li> 302 302 </ul> … … 324 324 <table class="form-table"> 325 325 <tr> 326 <th><?php _e( ' AlertHook ( Optional )', 'vk-all-in-one-expansion-unit' ); ?></th>326 <th><?php _e( 'Disclosure Hook ( Optional )', 'vk-all-in-one-expansion-unit' ); ?></th> 327 327 <td> 328 328 <p><?php _e( 'By default, it is output at the top of the content.', 'vk-all-in-one-expansion-unit' ); ?><br><?php _e( 'If you want to change the location of any action hook, enter the action hook name.', 'vk-all-in-one-expansion-unit' ); ?><br><?php _e( 'Ex) lightning_entry_body_prepend', 'vk-all-in-one-expansion-unit' ); ?></p> -
vk-all-in-one-expansion-unit/tags/9.112.2.0/inc/wp-title/package/wp-title.php
r3364608 r3393317 44 44 $options = vkExUnit_get_wp_title_options(); 45 45 if ( empty( $options['extend_frontTitle'] ) ) { 46 $title = get_bloginfo( 'name' ) . $sep . get_bloginfo( 'description' ); 46 $description = get_bloginfo( 'description' ); 47 $title = get_bloginfo( 'name' ); 48 if ( ! empty( $description ) ) { 49 $title .= $sep . $description; 50 } 47 51 } else { 48 52 $title = $options['extend_frontTitle']; -
vk-all-in-one-expansion-unit/tags/9.112.2.0/readme.txt
r3385606 r3393317 82 82 == Changelog == 83 83 84 = 9.112.2 = 85 [ Specification Change ][ Add Reusable block menu ] Change menu name "Manage all reusable blocks" -> "Patterns" 86 [ Specification Change ][ Promotion Alert ] Change UI labels from "Promotion Alert" to "Promotion Disclosure" for better accuracy of functionality description. 87 [ Bug Fix ] Fix CTA / Custom CSS XSS. 88 [ Bug Fix ][ Title Tag ] Prevent the separator from appearing on the front page when the site description is empty. 89 84 90 = 9.112.1 = 85 91 [ Bug Fix ][ Default Thumbnail ] Fix issue where default thumbnail appears in media library list view. -
vk-all-in-one-expansion-unit/tags/9.112.2.0/vendor/composer/installed.php
r3385606 r3393317 2 2 'root' => array( 3 3 'name' => 'vektor-inc/vk-all-in-one-expansion-unit', 4 'pretty_version' => '9.112. 1.1',5 'version' => '9.112. 1.1',6 'reference' => ' 3bcb4b718ff74b8e1ce17886c2e4093b139ee5fe',4 'pretty_version' => '9.112.2.0', 5 'version' => '9.112.2.0', 6 'reference' => '1971b26f7fb04a8d80222d09806b2a9cde75dbc8', 7 7 'type' => 'project', 8 8 'install_path' => __DIR__ . '/../../', … … 30 30 ), 31 31 'vektor-inc/vk-all-in-one-expansion-unit' => array( 32 'pretty_version' => '9.112. 1.1',33 'version' => '9.112. 1.1',34 'reference' => ' 3bcb4b718ff74b8e1ce17886c2e4093b139ee5fe',32 'pretty_version' => '9.112.2.0', 33 'version' => '9.112.2.0', 34 'reference' => '1971b26f7fb04a8d80222d09806b2a9cde75dbc8', 35 35 'type' => 'project', 36 36 'install_path' => __DIR__ . '/../../', -
vk-all-in-one-expansion-unit/tags/9.112.2.0/veu-packages.php
r3219607 r3393317 233 233 $required_packages[] = array( 234 234 'name' => 'addReusableBlockMenu', 235 'title' => __( 'Add Reusable blockmenu', 'vk-all-in-one-expansion-unit' ) . $deprecated,236 'description' => __( 'Add Manage all reusable blocks menu to admin menu.', 'vk-all-in-one-expansion-unit' ),235 'title' => __( 'Add Patterns menu', 'vk-all-in-one-expansion-unit' ) . $deprecated, 236 'description' => __( 'Add Patterns menu to admin menu.', 'vk-all-in-one-expansion-unit' ), 237 237 'default' => false, 238 238 'include' => 'add_menu_to_block_reuse.php', … … 352 352 353 353 /* 354 Promotion Alert354 Promotion Disclosure 355 355 */ 356 356 $required_packages[] = array( 357 357 'name' => 'promotion_alert', 358 'title' => __( 'Promotion Alert', 'vk-all-in-one-expansion-unit' ),359 'description' => __( 'If the article contains advertisements, it\'s essential to have a notationthat general consumers can recognize.', 'vk-all-in-one-expansion-unit' ) . '<br>' . __( 'Using this feature, you can automatically insert the content set in ExUnit > Main Settings into the post.', 'vk-all-in-one-expansion-unit' ),358 'title' => __( 'Promotion Disclosure', 'vk-all-in-one-expansion-unit' ), 359 'description' => __( 'If the article contains advertisements, it\'s essential to have a disclosure that general consumers can recognize.', 'vk-all-in-one-expansion-unit' ) . '<br>' . __( 'Using this feature, you can automatically insert the content set in ExUnit > Main Settings into the post.', 'vk-all-in-one-expansion-unit' ), 360 360 'attr' => array( 361 361 array( -
vk-all-in-one-expansion-unit/tags/9.112.2.0/vkExUnit.php
r3385606 r3393317 4 4 * Plugin URI: https://ex-unit.nagoya 5 5 * Description: This plug-in is an integrated plug-in with a variety of features that make it powerful your web site. Many features can be stopped individually. Example Facebook Page Plugin,Social Bookmarks,Print OG Tags,Print Twitter Card Tags,Print Google Analytics tag,New post widget,Insert Related Posts and more! 6 * Version: 9.112. 1.16 * Version: 9.112.2.0 7 7 * Requires PHP: 7.4 8 8 * Requires at least: 6.5 -
vk-all-in-one-expansion-unit/trunk/admin/class-veu-metabox.php
r3214209 r3393317 172 172 173 173 // nonce を確認し、値が書き換えられていれば、何もしない(CSRF対策) 174 if ( ! wp_verify_nonce( $noncename__value, wp_create_nonce( __FILE__ )) ) {174 if ( ! wp_verify_nonce( $noncename__value, __FILE__ ) ) { 175 175 return $post_id; 176 176 } -
vk-all-in-one-expansion-unit/trunk/inc/add_menu_to_block_reuse.php
r3214209 r3393317 11 11 $position = 20; 12 12 $menu_slug = 'edit.php?post_type=wp_block'; 13 $menu_title = __( ' Manage all reusable blocks', 'vk-all-in-one-expansion-unit' );13 $menu_title = __( 'Patterns', 'vk-all-in-one-expansion-unit' ); 14 14 15 15 while ( isset( $menu[ $position ] ) ) { -
vk-all-in-one-expansion-unit/trunk/inc/call-to-action/package/block/index.php
r3286716 r3393317 231 231 } 232 232 233 $url = get_post_meta( $cta_id, 'vkExUnit_cta_url', true);233 $url = esc_url( get_post_meta( $cta_id, 'vkExUnit_cta_url', true ) ); 234 234 $text = get_post_meta( $cta_id, 'vkExUnit_cta_text', true ); 235 235 $text = preg_replace( '/\n/', '<br/>', $text ); … … 282 282 283 283 // Display Edit Button. 284 $url = get_edit_post_link( $cta_post->ID);284 $url = esc_url( get_edit_post_link( $cta_post->ID ) ); 285 285 if ( $url ) { 286 286 $content .= '<div class="veu_adminEdit veu_adminEdit_cta"><a href="' . $url . '" class="btn btn-default" target="_blank">' . __( 'Edit CTA', 'vk-all-in-one-expansion-unit' ) . '</a></div>'; -
vk-all-in-one-expansion-unit/trunk/inc/call-to-action/package/class-vk-call-to-action.php
r3286716 r3393317 196 196 // カスタムフィールドの保存. 197 197 foreach ( $custom_fields as $custom_field_name => $custom_field_options ) { 198 $data = ''; 198 199 if ( isset( $_POST[ $custom_field_name ] ) ) { 199 if ( ! empty( $custom_field_ name['escape_type'] ) ) {200 if ( is_array( $custom_field_ name['escape_type'] ) ) {200 if ( ! empty( $custom_field_options['escape_type'] ) ) { 201 if ( is_array( $custom_field_options['escape_type'] ) ) { 201 202 // エスケープ処理が複数ある場合 202 203 $data = $_POST[ $custom_field_name ]; 203 foreach ( $custom_field_ name['escape_type'] as $escape ) {204 foreach ( $custom_field_options['escape_type'] as $escape ) { 204 205 $data = call_user_func( $escape, $data ); 205 206 } 206 207 } else { 207 208 // エスケープ処理が一つの場合 208 $data = call_user_func( $custom_field_ name['escape_type'], $_POST[ $custom_field_name ] );209 $data = call_user_func( $custom_field_options['escape_type'], $_POST[ $custom_field_name ] ); 209 210 } 210 211 } else { 212 // エスケープ処理が無い場合 211 213 $data = $_POST[ $custom_field_name ]; 212 214 } -
vk-all-in-one-expansion-unit/trunk/inc/css-customize/class-veu-metabox-css-customize.php
r3186987 r3393317 29 29 $form = ''; 30 30 31 $form .= '<textarea name="' . esc_attr( $this->args['cf_name'] ) . '" id="' . esc_attr( $this->args['cf_name'] ) . '" rows="5" cols="30" style="width:100%;">' . wp_kses_post( $cf_value ) . '</textarea>';31 $form .= '<textarea name="' . esc_attr( $this->args['cf_name'] ) . '" id="' . esc_attr( $this->args['cf_name'] ) . '" rows="5" cols="30" style="width:100%;">' . esc_textarea( $cf_value ) . '</textarea>'; 32 32 33 33 return $form; 34 } 35 36 /** 37 * Override parent save to sanitize CSS payloads before persisting. 38 * 39 * @param int $post_id Current post ID. 40 * @return int 41 */ 42 public function save_custom_field( $post_id ) { 43 44 if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { 45 return $post_id; 46 } 47 48 $nonce_key = 'noncename__' . $this->args['cf_name']; 49 $nonce_value = isset( $_POST[ $nonce_key ] ) ? $_POST[ $nonce_key ] : null; 50 51 if ( ! wp_verify_nonce( $nonce_value, __FILE__ ) ) { 52 return $post_id; 53 } 54 55 delete_post_meta( $post_id, $this->args['cf_name'] ); 56 57 if ( empty( $_POST[ $this->args['cf_name'] ] ) ) { 58 return $post_id; 59 } 60 61 $raw_css = wp_unslash( $_POST[ $this->args['cf_name'] ] ); 62 $sanitized_css = veu_sanitize_custom_css_input( $raw_css ); 63 if ( '' !== $sanitized_css ) { 64 add_post_meta( $post_id, $this->args['cf_name'], $sanitized_css ); 65 } 66 67 return $post_id; 34 68 } 35 69 } // class VEU_Metabox_CSS_Customize { -
vk-all-in-one-expansion-unit/trunk/inc/css-customize/css-customize-single.php
r3214209 r3393317 8 8 } 9 9 add_action( 'after_setup_theme', 'veu_css_customize_single_load', 11 ); 10 11 if ( ! function_exists( 'veu_sanitize_custom_css_input' ) ) { 12 /** 13 * Basic sanitization for the Custom CSS meta field. 14 * Removes HTML tags while keeping CSS-specific characters intact. 15 * 16 * @param string $css Raw CSS provided by editors. 17 * @return string Sanitized CSS string. 18 */ 19 function veu_sanitize_custom_css_input( $css ) { 20 if ( ! is_string( $css ) ) { 21 return ''; 22 } 23 24 $css = wp_check_invalid_utf8( $css ); 25 $css = html_entity_decode( $css, ENT_QUOTES | ENT_HTML5 ); 26 $css = wp_strip_all_tags( $css, false ); 27 $css = preg_replace( '/<\/?style[^>]*>/i', '', $css ); 28 $css = trim( $css ); 29 30 return $css; 31 } 32 } 10 33 11 34 /** … … 29 52 $css = veu_get_the_custom_css_single( $post ); 30 53 if ( $css ) { 31 // HTMLエンティティをデコードし、HTMLタグとその内容を削除 32 $css = html_entity_decode( $css, ENT_QUOTES | ENT_HTML5 ); 33 echo '<style type="text/css">/* ' . esc_html( veu_get_short_name() ) . ' CSS Customize Single */' . $css . '</style>'; 54 $css = veu_sanitize_custom_css_input( $css ); 55 if ( $css ) { 56 echo '<style type="text/css">/* ' . esc_html( veu_get_short_name() ) . ' CSS Customize Single */' . $css . '</style>'; 57 } 34 58 } 35 59 } … … 40 64 $css_customize = get_post_meta( $post->ID, '_veu_custom_css', true ); 41 65 if ( $css_customize ) { 66 $css_customize = veu_sanitize_custom_css_input( $css_customize ); 42 67 // Delete br 43 68 $css_customize = str_replace( PHP_EOL, '', $css_customize ); -
vk-all-in-one-expansion-unit/trunk/inc/promotion-alert/config.php
r3214209 r3393317 1 1 <?php 2 2 /** 3 * VEU Promotion AlertSetting3 * VEU Promotion Disclosure Setting 4 4 */ 5 5 -
vk-all-in-one-expansion-unit/trunk/inc/promotion-alert/package/class-veu-promotion-alert-metabox.php
r3214209 r3393317 1 1 <?php 2 2 /** 3 * VEU Metabox Promotion Alert3 * VEU Metabox Promotion Disclosure 4 4 */ 5 5 … … 16 16 'slug' => 'veu_display_promotion_alert', 17 17 'cf_name' => 'veu_display_promotion_alert', 18 'title' => __( 'Promotion AlertSetting', 'vk-all-in-one-expansion-unit' ),18 'title' => __( 'Promotion Disclosure Setting', 'vk-all-in-one-expansion-unit' ), 19 19 'priority' => 1, 20 20 ); … … 37 37 38 38 $form .= '<div class="veu_promotion-alert-meta-fields">'; 39 $form .= '<h4>' . __( 'Promotion AlertSetting', 'vk-all-in-one-expansion-unit' ) . '</h4>';39 $form .= '<h4>' . __( 'Promotion Disclosure Setting', 'vk-all-in-one-expansion-unit' ) . '</h4>'; 40 40 $form .= '<select name="veu_display_promotion_alert">'; 41 41 $form .= '<option value="common" ' . selected( $cf_value, 'common', false ) . '>' . __( 'Apply common settings', 'vk-all-in-one-expansion-unit' ) . '</option>'; -
vk-all-in-one-expansion-unit/trunk/inc/promotion-alert/package/class-veu-promotion-alert.php
r3214209 r3393317 1 1 <?php 2 2 /** 3 * VEU Promotion Alert3 * VEU Promotion Disclosure 4 4 */ 5 5 … … 202 202 public static function option_init() { 203 203 vkExUnit_register_setting( 204 __( 'Promotion Alert', 'vk-all-in-one-expansion-unit' ), // tab label.204 __( 'Promotion Disclosure', 'vk-all-in-one-expansion-unit' ), // tab label. 205 205 'vkExUnit_PA', // name attr 206 206 array( __CLASS__, 'sanitize_setting' ), // sanitaise function name … … 271 271 $options = self::get_options(); 272 272 ?> 273 <h3><?php _e( 'Promotion Alert', 'vk-all-in-one-expansion-unit' ); ?></h3>273 <h3><?php _e( 'Promotion Disclosure', 'vk-all-in-one-expansion-unit' ); ?></h3> 274 274 <div id="vkExUnit_PA" class="sectionBox"> 275 275 <P> 276 <?php _e( 'If the article contains advertisements, it\'s necessary to provide a clear notationfor general consumers to recognize.', 'vk-all-in-one-expansion-unit' ); ?>276 <?php _e( 'If the article contains advertisements, it\'s necessary to provide a clear disclosure for general consumers to recognize.', 'vk-all-in-one-expansion-unit' ); ?> 277 277 <br> 278 278 <?php _e( 'By inputting here, you can automatically insert it at the beginning of the article.', 'vk-all-in-one-expansion-unit' ); ?> … … 280 280 <table class="form-table"> 281 281 <tr> 282 <th><?php _e( ' AlertText', 'vk-all-in-one-expansion-unit' ); ?></th>282 <th><?php _e( 'Disclosure Text', 'vk-all-in-one-expansion-unit' ); ?></th> 283 283 <td> 284 284 <p> … … 294 294 </tr> 295 295 <tr> 296 <th><?php _e( 'Custom AlertContent', 'vk-all-in-one-expansion-unit' ); ?></th>296 <th><?php _e( 'Custom Disclosure Content', 'vk-all-in-one-expansion-unit' ); ?></th> 297 297 <td> 298 298 <textarea name="vkExUnit_PA[alert-content]" style="width:100%;" rows="10"><?php echo $options['alert-content']; ?></textarea> 299 299 <ul> 300 <li><?php _e( 'If there is any input in "Custom Alert Content", "Alert Text" will not be displayed and will be overwritten by the content entered in "Custom AlertContent".', 'vk-all-in-one-expansion-unit' ); ?></li>300 <li><?php _e( 'If there is any input in "Custom Disclosure Content", "Disclosure Text" will not be displayed and will be overwritten by the content entered in "Custom Disclosure Content".', 'vk-all-in-one-expansion-unit' ); ?></li> 301 301 <li><?php _e( 'You can insert HTML tags here. This is designed to be used by pasting content created in the Block Editor.', 'vk-all-in-one-expansion-unit' ); ?></li> 302 302 </ul> … … 324 324 <table class="form-table"> 325 325 <tr> 326 <th><?php _e( ' AlertHook ( Optional )', 'vk-all-in-one-expansion-unit' ); ?></th>326 <th><?php _e( 'Disclosure Hook ( Optional )', 'vk-all-in-one-expansion-unit' ); ?></th> 327 327 <td> 328 328 <p><?php _e( 'By default, it is output at the top of the content.', 'vk-all-in-one-expansion-unit' ); ?><br><?php _e( 'If you want to change the location of any action hook, enter the action hook name.', 'vk-all-in-one-expansion-unit' ); ?><br><?php _e( 'Ex) lightning_entry_body_prepend', 'vk-all-in-one-expansion-unit' ); ?></p> -
vk-all-in-one-expansion-unit/trunk/inc/wp-title/package/wp-title.php
r3364608 r3393317 44 44 $options = vkExUnit_get_wp_title_options(); 45 45 if ( empty( $options['extend_frontTitle'] ) ) { 46 $title = get_bloginfo( 'name' ) . $sep . get_bloginfo( 'description' ); 46 $description = get_bloginfo( 'description' ); 47 $title = get_bloginfo( 'name' ); 48 if ( ! empty( $description ) ) { 49 $title .= $sep . $description; 50 } 47 51 } else { 48 52 $title = $options['extend_frontTitle']; -
vk-all-in-one-expansion-unit/trunk/readme.txt
r3385606 r3393317 82 82 == Changelog == 83 83 84 = 9.112.2 = 85 [ Specification Change ][ Add Reusable block menu ] Change menu name "Manage all reusable blocks" -> "Patterns" 86 [ Specification Change ][ Promotion Alert ] Change UI labels from "Promotion Alert" to "Promotion Disclosure" for better accuracy of functionality description. 87 [ Bug Fix ] Fix CTA / Custom CSS XSS. 88 [ Bug Fix ][ Title Tag ] Prevent the separator from appearing on the front page when the site description is empty. 89 84 90 = 9.112.1 = 85 91 [ Bug Fix ][ Default Thumbnail ] Fix issue where default thumbnail appears in media library list view. -
vk-all-in-one-expansion-unit/trunk/vendor/composer/installed.php
r3385606 r3393317 2 2 'root' => array( 3 3 'name' => 'vektor-inc/vk-all-in-one-expansion-unit', 4 'pretty_version' => '9.112. 1.1',5 'version' => '9.112. 1.1',6 'reference' => ' 3bcb4b718ff74b8e1ce17886c2e4093b139ee5fe',4 'pretty_version' => '9.112.2.0', 5 'version' => '9.112.2.0', 6 'reference' => '1971b26f7fb04a8d80222d09806b2a9cde75dbc8', 7 7 'type' => 'project', 8 8 'install_path' => __DIR__ . '/../../', … … 30 30 ), 31 31 'vektor-inc/vk-all-in-one-expansion-unit' => array( 32 'pretty_version' => '9.112. 1.1',33 'version' => '9.112. 1.1',34 'reference' => ' 3bcb4b718ff74b8e1ce17886c2e4093b139ee5fe',32 'pretty_version' => '9.112.2.0', 33 'version' => '9.112.2.0', 34 'reference' => '1971b26f7fb04a8d80222d09806b2a9cde75dbc8', 35 35 'type' => 'project', 36 36 'install_path' => __DIR__ . '/../../', -
vk-all-in-one-expansion-unit/trunk/veu-packages.php
r3219607 r3393317 233 233 $required_packages[] = array( 234 234 'name' => 'addReusableBlockMenu', 235 'title' => __( 'Add Reusable blockmenu', 'vk-all-in-one-expansion-unit' ) . $deprecated,236 'description' => __( 'Add Manage all reusable blocks menu to admin menu.', 'vk-all-in-one-expansion-unit' ),235 'title' => __( 'Add Patterns menu', 'vk-all-in-one-expansion-unit' ) . $deprecated, 236 'description' => __( 'Add Patterns menu to admin menu.', 'vk-all-in-one-expansion-unit' ), 237 237 'default' => false, 238 238 'include' => 'add_menu_to_block_reuse.php', … … 352 352 353 353 /* 354 Promotion Alert354 Promotion Disclosure 355 355 */ 356 356 $required_packages[] = array( 357 357 'name' => 'promotion_alert', 358 'title' => __( 'Promotion Alert', 'vk-all-in-one-expansion-unit' ),359 'description' => __( 'If the article contains advertisements, it\'s essential to have a notationthat general consumers can recognize.', 'vk-all-in-one-expansion-unit' ) . '<br>' . __( 'Using this feature, you can automatically insert the content set in ExUnit > Main Settings into the post.', 'vk-all-in-one-expansion-unit' ),358 'title' => __( 'Promotion Disclosure', 'vk-all-in-one-expansion-unit' ), 359 'description' => __( 'If the article contains advertisements, it\'s essential to have a disclosure that general consumers can recognize.', 'vk-all-in-one-expansion-unit' ) . '<br>' . __( 'Using this feature, you can automatically insert the content set in ExUnit > Main Settings into the post.', 'vk-all-in-one-expansion-unit' ), 360 360 'attr' => array( 361 361 array( -
vk-all-in-one-expansion-unit/trunk/vkExUnit.php
r3385606 r3393317 4 4 * Plugin URI: https://ex-unit.nagoya 5 5 * Description: This plug-in is an integrated plug-in with a variety of features that make it powerful your web site. Many features can be stopped individually. Example Facebook Page Plugin,Social Bookmarks,Print OG Tags,Print Twitter Card Tags,Print Google Analytics tag,New post widget,Insert Related Posts and more! 6 * Version: 9.112. 1.16 * Version: 9.112.2.0 7 7 * Requires PHP: 7.4 8 8 * Requires at least: 6.5
Note: See TracChangeset
for help on using the changeset viewer.