Optimizing Performance in WordPress Rewrite Rules and Custom Query Variables for High-Traffic Content Portals
Understanding WordPress Rewrite Rule Performance Bottlenecks
High-traffic WordPress sites, particularly content portals, often encounter performance degradation due to inefficient rewrite rule processing. The core of WordPress’s permalink system relies on the Apache `mod_rewrite` (or Nginx equivalent) and WordPress’s internal rewrite engine. When a request hits the server, WordPress iterates through its registered rewrite rules to find a match. For sites with numerous custom post types, taxonomies, or complex URL structures, this can become a significant overhead, especially under heavy load. Each rule is essentially a regular expression that needs to be evaluated against the incoming URL.
The primary culprit is often the sheer volume and complexity of these rules. WordPress, plugins, and themes all contribute to the rewrite rule set. A poorly optimized rule, or a large number of rules, can lead to increased CPU usage and slower response times. Diagnosing this requires a deep dive into how WordPress generates and processes these rules.
Diagnosing Rewrite Rule Overload
The first step in optimization is accurate diagnosis. We need to quantify the number of rewrite rules and identify potential inefficiencies. WordPress provides a built-in mechanism to dump all rewrite rules, which is invaluable for this process.
Dumping Rewrite Rules
To inspect your site’s rewrite rules, you can temporarily add a snippet of PHP to your theme’s `functions.php` file or a custom plugin. This snippet will output the rules to the browser when a specific query variable is present in the URL. For instance, appending ?debug_rewrite_rules=1 to your site’s URL will trigger the output.
add_action( 'init', function() {
if ( isset( $_GET['debug_rewrite_rules'] ) && current_user_can( 'manage_options' ) ) {
global $wp_rewrite;
echo '<pre>';
print_r( $wp_rewrite->rules );
echo '</pre>';
exit; // Stop further execution to ensure clean output
}
});
Once you have the output, you’ll see a large array representing the rewrite rules. The keys are the regular expressions, and the values are the rewrite rule structures. A typical output might look like this (simplified):
Array
(
[endpoints] => Array
(
[0] => Array
(
[query] => index.php?rest_route=/wp/v2/posts
[args] => Array
(
[post__in] => Array
(
[0] => 1
)
)
[rewrite] => 1
)
)
[query] => Array
(
[^about/page/([0-9]+)/?$] => index.php?page=about&paged=$matches[1]
[^about/([^/]+)/?$] => index.php?page=about&name=$matches[1]
[^feed/?$] => index.php?feed=rss2
[^feed/rss/?$] => index.php?feed=rss2
[^feed/atom/?$] => index.php?feed=atom
[^comments/feed/?$] => index.php?feed=comments-rss2
[^wp-json/?$] => index.php?rest_route=/
[^wp-json/(.*)?$] => index.php?rest_route=/$matches[1]
[^wp-cron.php$] => wp-cron.php
[^wp-content/uploads/(?:[0-9]{4}/(?:0[1-9]|1[0-2])/.*|.*)$] => index.php?attachment=$matches[0]
[^wp-content/.*.php$] => index.php?error=403
[^.*.php$] => index.php?error=403
[page/([0-9]+)/?$] => index.php?paged=$matches[1]
[([^/]+)/page/([0-9]+)/?$] => index.php?name=$matches[1]&paged=$matches[2]
[([^/]+)/?$] => index.php?name=$matches[1]
[date/([0-9]{4})/([0-9]{2})/([0-9]{2})/([^/]+)/?$] => index.php?year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&name=$matches[4]
[date/([0-9]{4})/([0-9]{2})/([^/]+)/?$] => index.php?year=$matches[1]&monthnum=$matches[2]&name=$matches[3]
[date/([0-9]{4})/([^/]+)/?$] => index.php?year=$matches[1]&name=$matches[2]
[([^/]+)/([0-9]{4})/([0-9]{2})/([0-9]{2})/?$] => index.php?name=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]
[([^/]+)/([0-9]{4})/([0-9]{2})/?$] => index.php?name=$matches[1]&year=$matches[2]&monthnum=$matches[3]
[([^/]+)/([0-9]{4})/?$] => index.php?name=$matches[1]&year=$matches[2]
[([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]
[([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]/$matches[29]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]/$matches[29]/$matches[30]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]/$matches[29]/$matches[30]/$matches[31]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]/$matches[29]/$matches[30]/$matches[31]/$matches[32]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]/$matches[29]/$matches[30]/$matches[31]/$matches[32]/$matches[33]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]/$matches[29]/$matches[30]/$matches[31]/$matches[32]/$matches[33]/$matches[34]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[13]/$matches[14]/$matches[15]/$matches[16]/$matches[17]/$matches[18]/$matches[19]/$matches[20]/$matches[21]/$matches[22]/$matches[23]/$matches[24]/$matches[25]/$matches[26]/$matches[27]/$matches[28]/$matches[29]/$matches[30]/$matches[31]/$matches[32]/$matches[33]/$matches[34]/$matches[35]
[([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$] => index.php?name=$matches[1]/$matches[2]/$matches[3]/$matches[4]/$matches[5]/$matches[6]/$matches[7]/$matches[8]/$matches[9]/$matches[10]/$matches[11]/$matches[12]/$matches[1