- File:
-
- 1 edited
-
trunk/wp-admin/options-permalink.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/options-permalink.php
r16980 r15233 24 24 '<p>' . __('You must click the Save Changes button at the bottom of the screen for new settings to take effect.') . '</p>' . 25 25 '<p><strong>' . __('For more information:') . '</strong></p>' . 26 '<p>' . __('<a href="http://codex.wordpress.org/Settings_Permalinks_SubPanel" target="_blank"> Documentation on Permalinks Settings</a>') . '</p>' .27 '<p>' . __('<a href="http://codex.wordpress.org/Using_Permalinks" target="_blank"> Documentation on Using Permalinks</a>') . '</p>' .26 '<p>' . __('<a href="http://codex.wordpress.org/Settings_Permalinks_SubPanel" target="_blank">Permalinks Settings Documentation</a>') . '</p>' . 27 '<p>' . __('<a href="http://codex.wordpress.org/Using_Permalinks" target="_blank">Using Permalinks Documentation</a>') . '</p>' . 28 28 '<p>' . __('<a href="http://wordpress.org/support/" target="_blank">Support Forums</a>') . '</p>' 29 29 ); … … 36 36 */ 37 37 function add_js() { 38 ?>38 ?> 39 39 <script type="text/javascript"> 40 40 //<![CDATA[ 41 jQuery(document).ready(function() { 42 jQuery('input:radio.tog').change(function() { 43 if ( 'custom' == this.value ) 44 return; 45 jQuery('#permalink_structure').val( this.value ); 46 }); 47 jQuery('#permalink_structure').focus(function() { 48 jQuery("#custom_selection").attr('checked', 'checked'); 49 }); 50 }); 41 function GetElementsWithClassName(elementName, className) { 42 var allElements = document.getElementsByTagName(elementName); 43 var elemColl = new Array(); 44 for (i = 0; i < allElements.length; i++) { 45 if (allElements[i].className == className) { 46 elemColl[elemColl.length] = allElements[i]; 47 } 48 } 49 return elemColl; 50 } 51 52 function upit() { 53 var inputColl = GetElementsWithClassName('input', 'tog'); 54 var structure = document.getElementById('permalink_structure'); 55 var inputs = ''; 56 for (i = 0; i < inputColl.length; i++) { 57 if ( inputColl[i].checked && inputColl[i].value != '') { 58 inputs += inputColl[i].value + ' '; 59 } 60 } 61 inputs = inputs.substr(0,inputs.length - 1); 62 if ( 'custom' != inputs ) 63 structure.value = inputs; 64 } 65 66 function blurry() { 67 if (!document.getElementById) return; 68 69 var structure = document.getElementById('permalink_structure'); 70 structure.onfocus = function () { document.getElementById('custom_selection').checked = 'checked'; } 71 72 var aInputs = document.getElementsByTagName('input'); 73 74 for (var i = 0; i < aInputs.length; i++) { 75 aInputs[i].onclick = aInputs[i].onkeyup = upit; 76 } 77 } 78 79 window.onload = blurry; 51 80 //]]> 52 81 </script> … … 98 127 $wp_rewrite->set_tag_base( $tag_base ); 99 128 } 100 101 create_initial_taxonomies();102 129 } 103 130 … … 224 251 <?php do_settings_sections('permalink'); ?> 225 252 226 <?php submit_button(); ?> 253 <p class="submit"> 254 <input type="submit" name="submit" class="button-primary" value="<?php esc_attr_e('Save Changes') ?>" /> 255 </p> 227 256 </form> 228 257 <?php if ( !is_multisite() ) { ?> … … 233 262 <form action="options-permalink.php" method="post"> 234 263 <?php wp_nonce_field('update-permalink') ?> 235 <p><textarea rows="9" class="large-text readonly" name="rules" id="rules" readonly="readonly"><?php echo esc_ textarea( $wp_rewrite->iis7_url_rewrite_rules()); ?></textarea></p>264 <p><textarea rows="9" class="large-text readonly" name="rules" id="rules" readonly="readonly"><?php echo esc_html($wp_rewrite->iis7_url_rewrite_rules()); ?></textarea></p> 236 265 </form> 237 266 <p><?php _e('If you temporarily make your <code>web.config</code> file writable for us to generate rewrite rules automatically, do not forget to revert the permissions after rule has been saved.') ?></p> … … 240 269 <form action="options-permalink.php" method="post"> 241 270 <?php wp_nonce_field('update-permalink') ?> 242 <p><textarea rows="18" class="large-text readonly" name="rules" id="rules" readonly="readonly"><?php echo esc_ textarea( $wp_rewrite->iis7_url_rewrite_rules(true)); ?></textarea></p>271 <p><textarea rows="18" class="large-text readonly" name="rules" id="rules" readonly="readonly"><?php echo esc_html($wp_rewrite->iis7_url_rewrite_rules(true)); ?></textarea></p> 243 272 </form> 244 273 <p><?php _e('If you temporarily make your site’s root directory writable for us to generate the <code>web.config</code> file automatically, do not forget to revert the permissions after the file has been created.') ?></p> … … 250 279 <form action="options-permalink.php" method="post"> 251 280 <?php wp_nonce_field('update-permalink') ?> 252 <p><textarea rows="6" class="large-text readonly" name="rules" id="rules" readonly="readonly"><?php echo esc_ textarea( $wp_rewrite->mod_rewrite_rules()); ?></textarea></p>281 <p><textarea rows="6" class="large-text readonly" name="rules" id="rules" readonly="readonly"><?php echo esc_html($wp_rewrite->mod_rewrite_rules()); ?></textarea></p> 253 282 </form> 254 283 <?php endif; ?>
Note: See TracChangeset
for help on using the changeset viewer.