summaryrefslogtreecommitdiffstats
path: root/wp-inst/wp-admin/options-permalink.php
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2005-11-11 11:27:43 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2005-11-11 11:27:43 +0000
commitb92deb93cf1b425d3b0da113dce719ff3e7af839 (patch)
tree4579958b1d0169cf8d86ad2e55286c7b5be90148 /wp-inst/wp-admin/options-permalink.php
parentaa750edffae8aeb649b0b2f15900db988e588de7 (diff)
WP Merge
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@430 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-inst/wp-admin/options-permalink.php')
-rw-r--r--wp-inst/wp-admin/options-permalink.php25
1 files changed, 19 insertions, 6 deletions
diff --git a/wp-inst/wp-admin/options-permalink.php b/wp-inst/wp-admin/options-permalink.php
index f6998bc..5ddc682 100644
--- a/wp-inst/wp-admin/options-permalink.php
+++ b/wp-inst/wp-admin/options-permalink.php
@@ -104,27 +104,40 @@ else
<?php
$prefix = '';
-if ( !$is_apache )
+
+if ( ! got_mod_rewrite() )
$prefix = '/index.php';
+
+$structures = array(
+ '',
+ $prefix . '/%year%/%monthnum%/%day%/%postname%/',
+ $prefix . '/archives/%post_id%'
+ );
?>
<form name="form" action="options-permalink.php" method="post">
<h3><?php _e('Common options:'); ?></h3>
<p>
<label>
-<input name="selection" type="radio" value="<?php echo $prefix; ?>/%year%/%monthnum%/%day%/%postname%/" class="tog" <?php checked( $prefix . '/%year%/%monthnum%/%day%/%postname%/', $permalink_structure); ?> />
-<?php _e('Date and name based, example:'); ?> <code><?php echo get_settings('home') . $prefix . '/' . date('Y') . '/' . date('m') . '/' . date('d') . '/sample-post/'; ?></code>
+<input name="selection" type="radio" value="" class="tog" <?php checked('', $permalink_structure); ?> />
+<?php _e('Default'); ?><br /> <span> &raquo; <code><?php echo get_settings('home'); ?>/?p=123</code></span>
+ </label>
+</p>
+<p>
+ <label>
+<input name="selection" type="radio" value="<?php echo $structures[1]; ?>" class="tog" <?php checked($structures[1], $permalink_structure); ?> />
+<?php _e('Date and name based'); ?><br /> <span> &raquo; <code><?php echo get_settings('home') . $prefix . '/' . date('Y') . '/' . date('m') . '/' . date('d') . '/sample-post/'; ?></code></span>
</label>
</p>
<p>
<label>
-<input name="selection" type="radio" value="<?php echo $prefix; ?>/archives/%post_id%" class="tog" <?php checked( $prefix . '/archives/%post_id%', $permalink_structure); ?> />
-<?php _e('Numeric, example:'); ?> <code><?php echo get_settings('home') . $prefix ; ?>/archives/123</code>
+<input name="selection" type="radio" value="<?php echo $structures[2]; ?>" class="tog" <?php checked($structures[2], $permalink_structure); ?> />
+<?php _e('Numeric'); ?><br /> <span> &raquo; <code><?php echo get_settings('home') . $prefix ; ?>/archives/123</code></span>
</label>
</p>
<p>
<label>
<input name="selection" type="radio" value="custom" class="tog"
-<?php if ( $permalink_structure != $prefix . '/archives/%post_id%' && $permalink_structure != $prefix . '/%year%/%monthnum%/%day%/%postname%/' ) { ?>
+<?php if ( !in_array($permalink_structure, $structures) ) { ?>
checked="checked"
<?php } ?>
/>