Skip Navigation

[Résolu] Use WP REST API to create and view custom post from another website

Ce fil est résolu. Voici une description du problème et la solution proposée.

Problem:
How to use REST API with Toolset

Solution:
This needs pure custom programming and that is beyond the scope of our support policy.

However I've mentioned few useful links with the following reply:
=> https://toolset.com/forums/topic/use-wp-rest-api-to-create-and-view-custom-post-from-another-website/#post-603277

Relevant Documentation:

This support ticket is created Il y a 6 années et 11 mois. 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.

Aucun de nos assistants n'est disponible aujourd'hui sur le forum Jeu d'outils. Veuillez créer un ticket, et nous nous le traiterons dès notre prochaine connexion. Merci de votre compréhension.

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)

Ce sujet contient 6 réponses, a 2 voix.

Dernière mise à jour par davidZ-4 Il y a 6 années et 10 mois.

Assisté par: Minesh.

Auteur
Publications
#603196

Tell us what you are trying to do? i would like to use the WP REST API to create, update and view custom posts.

Is there any documentation that you are following?
i believe https://developer.wordpress.org/rest-api/ have some of the information

Is there a similar example that we can see?
I'm not sure

What is the link to your site? lien caché

#603277

Minesh
Supporter

Les langues: Anglais (English )

Fuseau horaire: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Well - this is pure custom programming and that is beyond the scope of our support policy.

However you can search for plugins on wordrepss.org and play with it if that suits to your requirements:
=> http://wordpress.stackexchange.com/questions/185641/show-popular-post-in-another-php-website-via-wp-rest-json-api
=> https://wordpress.org/plugins/json-rest-api/
=> https://wordpress.org/plugins/rest-api/

Still I have few articles to share with you which you can use as reference:
=> https://www.gavick.com/blog/adding-custom-fields-in-the-wordpress-rest-api
=> https://code.tutsplus.com/tutorials/wp-rest-api-creating-updating-and-deleting-data--cms-24883

If you want custom programming for your project, Please feel free to contact our certified partners.
=> https://toolset.com/consultant/

#604187

HI Minesh,

working with the REST API is now native in WordPress and does not require plugins...
i understand the GET, PUT, POST and DELETE concepts of the API.

my issue is a bit different. allow me to elaborate

when using Types with CRED and Views i can limit the user views and content submissions. in my case each user can create his own private posts and view only his own posts. he can not see others posts.

when using the REST API i would like to get the same restrictions i.e. the user must be authenticated somehow to create and pull only his own posts. not sure how to implement this with REST API.

I have seen some references to https://wordpress.org/plugins/views-output-formats/ and lien caché
I'm not sure if this is something you support or plan to enable.

BTW I'm on https://toolset.com/consultant/

Please advise,
thanks,

David

#604191

Minesh
Supporter

Les langues: Anglais (English )

Fuseau horaire: Asia/Kolkata (GMT+05:30)

Well - the this answer you may not give you satisfaction but as I admit we need to work within our defined support boundary and support you are requesting is beyond the scope of our support policy.

Yes - you done right thing. Please contact our certified partners for further help on your custom request.

#604192

OK,
I understand.

Thanks,

David

#604195

Minesh
Supporter

Les langues: Anglais (English )

Fuseau horaire: Asia/Kolkata (GMT+05:30)

Great!! Thank you for understanding. You can close this ticket now.

#604438

Closing.