Make WordPress Core

Ticket #28165: themes.php.diff

File themes.php.diff, 849 bytes (added by ideag, 10 years ago)
  • wp-admin/themes.php

     
    249249        </tr>
    250250<?php
    251251        foreach ( $broken_themes as $broken_theme ) {
     252                $slug = $broken_theme->get( 'Name' ) ? $broken_theme->get( 'Name' ) : $broken_theme->get_stylesheet();
     253                $encoded_slug = urlencode($slug);
    252254                echo "
    253255                <tr>
    254256                         <td>" . ( $broken_theme->get( 'Name' ) ? $broken_theme->get( 'Name' ) : $broken_theme->get_stylesheet() ) . "</td>
    255257                         <td>" . $broken_theme->errors()->get_error_message() . "</td>
     258                         <td><a href=\"" . wp_nonce_url( admin_url( 'themes.php?action=delete&stylesheet=' . $encoded_slug ), 'delete-theme_' . $slug ) . "\" class=\"button button-secondary delete-theme\">" . __( 'Delete' ) . "</a></td>
    256259                </tr>";
    257260        }
    258261?>