Making WordPress.org


Ignore:
Timestamp:
12/12/2022 03:55:38 AM (18 months ago)
Author:
dd32
Message:

Plugin Directory: Simplify the 'sections' titles, as we don't need anything more than the title here.

This replaces [12315-12318] with simpler code, as the cause was a previous design choice interacting with unexpected data.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/template-parts/section-blocks.php

    r11355 r12319  
    88 */
    99
    10 global $section, $section_slug, $section_content;
     10global $section_slug, $section_title, $section_content;
    1111
    1212$prefix = in_array( $section_slug, array( 'screenshots', 'faq', 'blocks' ), true ) ? '' : 'tab-';
     
    3737
    3838<div id="<?php echo esc_attr( $prefix . $section_slug ); ?>" class="<?php echo esc_attr( $classes ); ?>">
    39     <h2 id="<?php echo esc_attr( $section_slug . '-header' ); ?>"><?php echo esc_html( $section['title'] ); ?></h2>
     39    <h2 id="<?php echo esc_attr( $section_slug . '-header' ); ?>"><?php echo esc_html( $section_title ); ?></h2>
    4040
    4141    <p><?php printf( esc_html( _n( 'This plugin provides %d block.', 'This plugin provides %d blocks.', count( $section_content ), 'wporg-plugins'  ) ), count( $section_content ) ); ?></p>
Note: See TracChangeset for help on using the changeset viewer.