GET request return value as error instead of success
I am trying to send response back to ajax request in js by using REST API.
I am trying to send response back to ajax request in js by using REST API.
I am trying to set up a custom endpoint which only returns some user data instead of the default data sent back by the users endpoint. But I don’t know how to get the first and last name of the user from WP_User_Query
I use below code for get last products from wp-json rest api
Below is what I have so far for a custom rest endpoint (‘placesdb/v1/search?term=’) for a custom post type (place). This successfully returns all the places that have the search term in the title or content. However, I also want to return all the tags (tag archive pages) that match the search term (the same result as calling the non-custom ‘/wp/v2/tags?search=’). Is it possible to somehow add the tag results to the place results? I already successfully did the front-end approach of calling the places and tags endpoints separately via ajax, but I would rather get all the data in one swoop. Hence my attempt at making this custom endpoint.
I am not sure if this is the right way to do it but I have a react site using WordPress API as the backend. I want to store my contact form entries in WordPress so I created a custom post type
I’ve been tasked with managing a WordPress site that was developed and configured by some other team. During a basic security scan, I’ve realized that the following end-point https://www.mywordpress.com/wp-json does not restrict the Origin for some reason.
I’m trying out adding WordPress REST API endpoints. I would now like to add an endpoint that retrieves a list of available plugin, theme and core updates.
I’m trying to register a GET REST API route with multiple parameters with the following code:
I have a Custom API End Point to query data from another blog in WPMU, the custom end point loads and I am able to return some data, but the specific query I need returns 0 posts.
I am able to create a new post by sending a request with cURL against the REST API. That works fine.