Saltar navegación

[Resuelto] Custom url attribute

Este hilo está resuelto. Aquí tiene una descripción del problema y la solución.

Problem:
How to Pass Custom url attribute

Solution:

You can find the proposed solution, in this case, with the following reply:
https://toolset.com/forums/topic/custom-url-attribute/#post-1099506

Relevant Documentation:
=> https://stackoverflow.com/questions/4586835/how-to-pass-extra-variables-in-url-with-wordpress
=> https://www.rlmseo.com/blog/passing-get-query-string-parameters-in-wordpress-url/

This support ticket is created hace 6 años, 3 meses. 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
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

Este tema contiene 6 respuestas, tiene 2 mensajes.

Última actualización por SteffenM1628 hace 6 años, 3 meses.

Asistido por: Minesh.

Autor
Mensajes
#1099322

Hey there!
Somehow i don’t get the „parse attributes“ to the URL.

I try this to build:
User can create a cpt via a form.
In the form the user should have the ability (field) to
Bring in a custom attribute to the cpt type url.

E.g. the custom post types url is enlace oculto
User decides to take 1234 as an url attribute
The url should be like
enlace oculto

Thanjs for your help

#1099328

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Well - do you want to override the post-slug for the new post which is created using Types plugin.

So, for example:
- I'm creating a new post with title "This is my post" and for this the slug will be "this-is-my-post".

Do you want a way to override "this-is-my-post" to a custom value which user will input in custom field?

#1099330

Hey minesh,

No actually i don’t want to change the slug or the title.

I just want to add an additional attribute to the url which the user defines via the form of the cpt.

Like this: "this-is-my-post/additional-attribute“

Thank you

#1099506

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

No - there is no such feature exists.

That needs custom programming which is beyond the scope of our support policy, If you need custom programming for your project, please feel free to contact our certified partners.
=> https://toolset.com/contractors/

However, please check following links that may help you:
=> https://stackoverflow.com/questions/4586835/how-to-pass-extra-variables-in-url-with-wordpress
=> enlace oculto
=> https://wordpress.stackexchange.com/questions/51444/add-extra-parameters-after-permalink
=>

#1099670

hey minesh,

thanks for your reply.
1. But for what are the 'urlparam=' in the form fields shortcodes for? (screenshot)
2. When this is not possible - is there a way to check the title of the post is unique?
3. A user creates the cpt. can he secure his post type from user?
e.g. user B wants to see the cpt from user A. user B has to put in a code or password to see the post

Thanks for your help

#1100641

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

1. But for what are the 'urlparam=' in the form fields shortcodes for? (screenshot)
==> The 'urlparam=' in forms fields is used to fill the values of fields using urlparam.

2. When this is not possible - is there a way to check the title of the post is unique?
I think you should check following link to check for duplicate post titleL
==> enlace oculto

3. A user creates the cpt. can he secure his post type from user?
e.g. user B wants to see the cpt from user A. user B has to put in a code or password to see the post
==> Do you mean private post? See following image: enlace oculto

#1100787

allright and thanks for your support.