| 1 | diff -r 2_5_1/wp-admin/includes/update.php test/wp-admin/includes/update.php
|
|---|
| 2 | 113a114,118
|
|---|
| 3 | > // testing purposes
|
|---|
| 4 | > // Assumes that server response will be changed to include a new element: an array "other_plugins" containing elements of $plugin_file=>'unknown' or $plugin_filename=>'current' for all the plugins for which it doesn't show updates.
|
|---|
| 5 | > $response['other_plugins'] = array('kill_messages.php'=>'unknown','kill_one_message.php'=>'unknown');
|
|---|
| 6 | > error_log( print_r($response,true) );
|
|---|
| 7 | >
|
|---|
| 8 | 140a146,162
|
|---|
| 9 | > function wp_plugin_update_unknown( $file ) {
|
|---|
| 10 | > $output = false;
|
|---|
| 11 | > $output = apply_filters('plugin_updates_unknown', $output, $file );
|
|---|
| 12 | > // Note: if filter returns false, function shows default message
|
|---|
| 13 | > // if filter returns empty string ('') function shows nothing
|
|---|
| 14 | > if( $output === false ) {
|
|---|
| 15 | > $current = get_option( 'update_plugins' );
|
|---|
| 16 | > $output = '';
|
|---|
| 17 | > if ( ( isset( $current->response['other_plugins'][ $file ] ) &&
|
|---|
| 18 | > $current->response['other_plugins'][ $file ] == 'unknown' ) ) {
|
|---|
| 19 | > $output = __('Not Checked for Updates');
|
|---|
| 20 | > $output = "<br /><span class=\"updatenotice\">{$output}</span>";
|
|---|
| 21 | > }
|
|---|
| 22 | > }
|
|---|
| 23 | > return $output;
|
|---|
| 24 | > }
|
|---|
| 25 | >
|
|---|
| 26 | diff -r 2_5_1/wp-admin/plugins.php test/wp-admin/plugins.php
|
|---|
| 27 | 146c146
|
|---|
| 28 | < <td class='vers'>{$plugin_data['Version']}</td>
|
|---|
| 29 | ---
|
|---|
| 30 | > <td class='vers'>{$plugin_data['Version']}" . wp_plugin_update_unknown($plugin_file) . "</td>
|
|---|
| 31 | diff -r 2_5_1/wp-admin/wp-admin.css test/wp-admin/wp-admin.css
|
|---|
| 32 | 4a5,15
|
|---|
| 33 | > #plugins span.updatenotice {
|
|---|
| 34 | > display: block;
|
|---|
| 35 | > margin-top: .5em;
|
|---|
| 36 | > font-style: italic;
|
|---|
| 37 | > font-size: 85%;
|
|---|
| 38 | > }
|
|---|
| 39 | >
|
|---|
| 40 | > #plugins .vers {
|
|---|
| 41 | > width: 7em;
|
|---|
| 42 | > }
|
|---|
| 43 | >
|
|---|
| 44 | Only in test/wp-content/plugins: kill_messages.php
|
|---|
| 45 | Only in test/wp-content/plugins: kill_one_message.php
|
|---|