Making WordPress.org

Ticket #2779: plugin-single-title-fix.patch

File plugin-single-title-fix.patch, 1.0 KB (added by joostdevalk, 7 years ago)

Patch that removes link from title on non-advanced page

  • wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/template-parts/plugin-single.php

    diff --git wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/template-parts/plugin-single.php wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/template-parts/plugin-single.php
    index 9d21434e..2dbac72d 100644
    $content = Plugin_Directory::instance()->split_post_content_into_pages( get_the_ 
    104104                                return $post->post_name;
    105105                        }, 10, 2 );
    106106                }
    107                 the_title( '<h1 class="plugin-title"><a href="' . esc_url( get_permalink() ) . '">', '</a></h1>' ); ?>
     107                if ( ! get_query_var( 'plugin_advanced' ) ) {
     108                        the_title( '<h1 class="plugin-title">', '</h1>' );
     109                } else {
     110                        the_title( '<h1 class="plugin-title"><a href="' . esc_url( get_permalink() ) . '">', '</a></h1>' );
     111        }
     112
     113        ?>
    108114
    109115        <span class="byline"><?php
    110116                        $url    = get_post_meta( get_the_ID(), 'header_author_uri', true );