Ticket #5607: remove_admin_notices11.diff
File remove_admin_notices11.diff, 4.7 KB (added by , 17 years ago) |
---|
-
wp-admin/edit-link-form.php
14 14 function xfn_check($class, $value = '', $deprecated = '') { 15 15 global $link; 16 16 17 $link_rel = $link->link_rel;17 $link_rel = ( isset($link->link_rel) ) ? $link->link_rel : null; 18 18 $rels = preg_split('/\s+/', $link_rel); 19 19 20 20 if ('' != $value && in_array($value, $rels) ) { … … 51 51 <h3 class="dbx-handle"><?php _e('Target') ?></h3> 52 52 <div class="dbx-content"> 53 53 <label for="link_target_blank" class="selectit"> 54 <input id="link_target_blank" type="radio" name="link_target" value="_blank" <?php echo(( $link->link_target == '_blank') ? 'checked="checked"' : ''); ?> />54 <input id="link_target_blank" type="radio" name="link_target" value="_blank" <?php echo((isset($link->link_target) && $link->link_target == '_blank') ? 'checked="checked"' : ''); ?> /> 55 55 <code>_blank</code></label> 56 56 <label for="link_target_top" class="selectit"> 57 <input id="link_target_top" type="radio" name="link_target" value="_top" <?php echo(( $link->link_target == '_top') ? 'checked="checked"' : ''); ?> />57 <input id="link_target_top" type="radio" name="link_target" value="_top" <?php echo((isset($link->link_target) && $link->link_target == '_top') ? 'checked="checked"' : ''); ?> /> 58 58 <code>_top</code></label> 59 59 <label for="link_target_none" class="selectit"> 60 <input id="link_target_none" type="radio" name="link_target" value="" <?php echo(( $link->link_target == '') ? 'checked="checked"' : ''); ?> />60 <input id="link_target_none" type="radio" name="link_target" value="" <?php echo((isset($link->link_target) && $link->link_target == '') ? 'checked="checked"' : ''); ?> /> 61 61 <?php _e('none') ?></label> 62 62 </div> 63 63 </fieldset> … … 84 84 </tr> 85 85 <tr> 86 86 <th width="20%" scope="row" valign="top"><label for="link_url"><?php _e('Address:') ?></label></th> 87 <td width="80%"><input type="text" name="link_url" id="link_url" value="<?php echo $link->link_url; if ( empty( $link->link_url ) ) echo 'http://'; ?>" style="width: 95%" /></td>87 <td width="80%"><input type="text" name="link_url" id="link_url" value="<?php echo ( empty( $link->link_url ) ) ? 'http://' : $link->link_url; ?>" style="width: 95%" /></td> 88 88 </tr> 89 89 <tr> 90 90 <th scope="row" valign="top"><label for="link_description"><?php _e('Description:') ?></label></th> 91 <td><input type="text" name="link_description" id="link_description" value="<?php echo $link->link_description; ?>" style="width: 95%" /></td>91 <td><input type="text" name="link_description" id="link_description" value="<?php echo ( ! empty( $link->link_description ) ) ? $link->link_description : ''; ?>" style="width: 95%" /></td> 92 92 </tr> 93 93 </table> 94 94 … … 104 104 <table class="editform" width="100%" cellspacing="2" cellpadding="5"> 105 105 <tr> 106 106 <th width="20%" scope="row"><?php _e('rel:') ?></th> 107 <td width="80%"><input type="text" name="link_rel" id="link_rel" size="50" value="<?php echo $link->link_rel; ?>" /></td>107 <td width="80%"><input type="text" name="link_rel" id="link_rel" size="50" value="<?php echo ( ! empty($link->link_rel) ) ? $link->link_rel : ''; ?>" /></td> 108 108 </tr> 109 109 <tr> 110 110 <th scope="row"><?php _e('<a href="http://gmpg.org/xfn/">XFN</a> Creator:') ?></th> … … 217 217 <table class="editform" width="100%" cellspacing="2" cellpadding="5"> 218 218 <tr> 219 219 <th width="20%" scope="row"><?php _e('Image Address:') ?></th> 220 <td width="80%"><input type="text" name="link_image" size="50" value="<?php echo $link->link_image; ?>" style="width: 95%" /></td>220 <td width="80%"><input type="text" name="link_image" size="50" value="<?php echo ( isset($link->link_image) ) ? $link->link_image : ''; ?>" style="width: 95%" /></td> 221 221 </tr> 222 222 <tr> 223 223 <th scope="row"><?php _e('RSS Address:') ?> </th> 224 <td><input name="link_rss" type="text" id="rss_uri" value="<?php echo $link->link_rss; ?>" size="50" style="width: 95%" /></td>224 <td><input name="link_rss" type="text" id="rss_uri" value="<?php echo ( isset($link->link_rss) ) ? $link->link_rss : ''; ?>" size="50" style="width: 95%" /></td> 225 225 </tr> 226 226 <tr> 227 227 <th scope="row"><?php _e('Notes:') ?></th> 228 <td><textarea name="link_notes" cols="50" rows="10" style="width: 95%"><?php echo $link->link_notes; ?></textarea></td>228 <td><textarea name="link_notes" cols="50" rows="10" style="width: 95%"><?php echo ( isset($link->link_notes) ) ? $link->link_notes : ''; ?></textarea></td> 229 229 </tr> 230 230 <tr> 231 231 <th scope="row"><?php _e('Rating:') ?></th> … … 233 233 <?php 234 234 for ($r = 0; $r < 10; $r++) { 235 235 echo(' <option value="'.$r.'" '); 236 if ( $link->link_rating == $r)236 if (isset($link->link_rating) && $link->link_rating == $r) 237 237 echo 'selected="selected"'; 238 238 echo('>'.$r.'</option>'); 239 239 }