Saltar navegación

[Resuelto] CPT Permalink Format

This support ticket is created 4 years, 11 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 - - 9:00 – 13:00
14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 - - 14:00 – 18:00

Zona horaria del colaborador: Africa/Casablanca (GMT+01:00)

Este tema contiene 3 respuestas, tiene 2 mensajes.

Última actualización por Jamal 4 years, 10 months ago.

Asistido por: Jamal.

Autor
Mensajes
#2110785

Currently my WordPress permalink structure like this

enlace oculto{post-slug}-{post_id}

but my CPT permalink shows like this

enlace oculto{cpt-slug}/{post-slug}

is it possible to change CPT permalink as showed below

enlace oculto{post-slug}-{post_id}

I dont want to show my CPT Slug in my URL, is there any way to workaround ?

#2110941

Hello and thank you for contacting Toolset support.

WordPress custom post types have the following permalink structure enlace oculto{cpt-slug}/{post-slug}

The only customization possible, out of the box, is changing the cpt-slug by something else. You can do it in the rewrite option in the custom post definition, check this screenshot enlace oculto

Apart from that, it is not something possible with Toolset. It will require custom code for custom rewrite rules. Read more about it here:
- https://developer.wordpress.org/apis/handbook/rewrite/
- https://developer.wordpress.org/reference/functions/add_rewrite_rule/
- enlace oculto

Please note that such custom code is out of the scope of Toolset support.

#2113185

through rewrite option can I omit cpt-slug ?

as if I want like this

enlace oculto{post-slug}

#2113225

Well, with rewrite rules custom code, you can theoretically do whatever you want. However, that's not within the Toolset support. We will not provide any examples or solutions about it. You may want to check online support communities, such as StackExchange or StackOverflow. Or you may want to hire a developer to do it for you. Below the list of our certified developers https://toolset.com/contractors/

This is the WordPress StackExchange community: https://wordpress.stackexchange.com/