wpseek.com
Bazujące na WordPress narzędzie wyszukiwania dla deweloperów i twórców motywów.



pre_wp_unique_post_slug › Filtr WordPress Hooks

Od5.1.0
Przestarzałyn/a
› apply_filters( 'pre_wp_unique_post_slug', null, $slug, $post_id, $post_status, $post_type, $post_parent )
Parametry: (6)
  • () override_slug Short-circuit return value.
    Wymagane: Tak
  • () slug The desired slug (post_name).
    Wymagane: Tak
  • () post_id Post ID.
    Wymagane: Tak
  • () post_status The post status.
    Wymagane: Tak
  • () post_type Post type.
    Wymagane: Tak
  • () post_parent Post parent ID.
    Wymagane: Tak
Zdefiniowane na:
Codex:

Filters the post slug before it is generated to be unique.

Returning a non-null value will short-circuit the unique slug generation, returning the passed value instead.




Źródło

$override_slug = apply_filters( 'pre_wp_unique_post_slug', null, $slug, $post_id, $post_status, $post_type, $post_parent );