Version Description
- /bug fix.
- taxonomy tmplate bug fix.
Download this release
Release Info
Developer | Toro_Unit |
Plugin | Custom Post Type Permalinks |
Version | 0.9.5.3 |
Comparing to | |
See all releases |
Code changes from version 0.9.5.2 to 0.9.5.3
- CPTP/Module/Rewrite.php +8 -9
- custom-post-type-permalinks.php +1 -1
- readme.txt +5 -1
CPTP/Module/Rewrite.php
CHANGED
@@ -52,7 +52,6 @@ class CPTP_Module_Rewrite extends CPTP_Module {
|
|
52 |
$wp_rewrite->add_rewrite_tag( "%$taxonomy%", '(.+?)', "$taxonomy=" );
|
53 |
endforeach;
|
54 |
|
55 |
-
$permalink = trim($permalink, "/" );
|
56 |
$rewrite_args = $args->rewrite;
|
57 |
if( !is_array($rewrite_args) ) {
|
58 |
$rewrite_args = array( 'with_front' => $args->rewrite );
|
@@ -140,16 +139,16 @@ class CPTP_Module_Rewrite extends CPTP_Module {
|
|
140 |
|
141 |
|
142 |
//add taxonomy slug
|
143 |
-
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/page/?([0-9]{1,})/?$', 'index.php?'.$tax.'=$matches[1]&paged=$matches[2]
|
144 |
-
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/feed/(feed|rdf|rss|rss2|atom)/?$', 'index.php?'.$tax.'=$matches[1]&feed=$matches[2]
|
145 |
-
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/(feed|rdf|rss|rss2|atom)/?$', 'index.php?'.$tax.'=$matches[1]&feed=$matches[2]
|
146 |
-
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/?$', 'index.php?'.$tax.'=$matches[1]
|
147 |
|
148 |
// below rules were added by [steve]
|
149 |
-
add_rewrite_rule( $taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]
|
150 |
-
add_rewrite_rule( $taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]&paged=$matches[4]
|
151 |
-
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]
|
152 |
-
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]&paged=$matches[4]
|
153 |
|
154 |
endforeach;
|
155 |
|
52 |
$wp_rewrite->add_rewrite_tag( "%$taxonomy%", '(.+?)', "$taxonomy=" );
|
53 |
endforeach;
|
54 |
|
|
|
55 |
$rewrite_args = $args->rewrite;
|
56 |
if( !is_array($rewrite_args) ) {
|
57 |
$rewrite_args = array( 'with_front' => $args->rewrite );
|
139 |
|
140 |
|
141 |
//add taxonomy slug
|
142 |
+
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/page/?([0-9]{1,})/?$', 'index.php?'.$tax.'=$matches[1]&paged=$matches[2]', 'top' );
|
143 |
+
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/feed/(feed|rdf|rss|rss2|atom)/?$', 'index.php?'.$tax.'=$matches[1]&feed=$matches[2]', 'top' );
|
144 |
+
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/(feed|rdf|rss|rss2|atom)/?$', 'index.php?'.$tax.'=$matches[1]&feed=$matches[2]', 'top' );
|
145 |
+
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/?$', 'index.php?'.$tax.'=$matches[1]', 'top' ); // modified by [steve] [*** bug fixing]
|
146 |
|
147 |
// below rules were added by [steve]
|
148 |
+
add_rewrite_rule( $taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]', 'top' );
|
149 |
+
add_rewrite_rule( $taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]&paged=$matches[4]', 'top' );
|
150 |
+
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]', 'top' );
|
151 |
+
add_rewrite_rule( $slug.'/'.$taxonomypat.'/(.+?)/date/([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$', 'index.php?'.$tax.'=$matches[1]&year=$matches[2]&monthnum=$matches[3]&paged=$matches[4]', 'top' );
|
152 |
|
153 |
endforeach;
|
154 |
|
custom-post-type-permalinks.php
CHANGED
@@ -5,7 +5,7 @@ Plugin URI: http://www.torounit.com
|
|
5 |
Description: Add post archives of custom post type and customizable permalinks.
|
6 |
Author: Toro_Unit
|
7 |
Author URI: http://www.torounit.com/plugins/custom-post-type-permalinks/
|
8 |
-
Version: 0.9.5.
|
9 |
Text Domain: cptp
|
10 |
License: GPL2 or later
|
11 |
Domain Path: /language/
|
5 |
Description: Add post archives of custom post type and customizable permalinks.
|
6 |
Author: Toro_Unit
|
7 |
Author URI: http://www.torounit.com/plugins/custom-post-type-permalinks/
|
8 |
+
Version: 0.9.5.3
|
9 |
Text Domain: cptp
|
10 |
License: GPL2 or later
|
11 |
Domain Path: /language/
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: Toro_Unit
|
|
3 |
Tags: permalink,permalinks,custom post type,custom taxonomy,cms
|
4 |
Requires at least: 3.7
|
5 |
Tested up to: 3.8
|
6 |
-
Stable tag: 0.9.5.
|
7 |
|
8 |
Lets you edit the permalink of custom post type.
|
9 |
|
@@ -40,6 +40,10 @@ That's it. You can access the permalinks setting by going to *Settings -> Permal
|
|
40 |
|
41 |
|
42 |
== Changelog ==
|
|
|
|
|
|
|
|
|
43 |
|
44 |
= 0.9.5.2 =
|
45 |
* Archives Rewrite Fix.
|
3 |
Tags: permalink,permalinks,custom post type,custom taxonomy,cms
|
4 |
Requires at least: 3.7
|
5 |
Tested up to: 3.8
|
6 |
+
Stable tag: 0.9.5.3
|
7 |
|
8 |
Lets you edit the permalink of custom post type.
|
9 |
|
40 |
|
41 |
|
42 |
== Changelog ==
|
43 |
+
|
44 |
+
= 0.9.5.3 =
|
45 |
+
* “/”bug fix.
|
46 |
+
* taxonomy tmplate bug fix.
|
47 |
|
48 |
= 0.9.5.2 =
|
49 |
* Archives Rewrite Fix.
|