WordPress.org

Ready to get started?Download WordPress

Codex

Function Reference/avoid blog page permalink collision

Contents

Description

This function is applied to the filter 'wp_insert_post_data'. On subdirectory multisite installs, it filters Pages' 'post_name' (URL slug) field to ensure that there is no conflict with any of the subdirectory links.

Example

If you have a one of your sites set up on a sub-directory 'my-site', and then publish a page on your main site titled "My Site", the slug would by default be 'my-site'. So the URL of the site on your network would be http://www.example.com/my-site/, but that would also be the URL of that page. The avoid_blog_page_permalink_collision() function fixes this conflict by appending a random string to the page's slug.

Change Log

Source File

avoid_blog_page_permalink_collision() is located in wp-admin/includes/ms.php.

See also index of Function Reference and index of Template Tags.
This page is marked as incomplete. You can help Codex by expanding it.