Unless you want to use PHP to run queries directly on your database, you’ll have to use a REST API and Javascript to gather the data. One point worth noting is these REST API’s also use direct database queries in order to gather info to return to you when you make a request. This means that any updates to WordPress database structure that would break your app if you wrote PHP to access the DB would also break the API plugin you use. The only difference is most plugin devs are pretty quick as far as updates go when their code becomes deprecated, and may be able to fix any issues faster than you could.
Here’s one JSON API plugin I found in the WordPress repo: http://wordpress.org/plugins/json-api/
I’m sure there are others. Just look around. Let me know if this helps clarify things a bit.
Related Posts:
- How to properly insert data into custom table via plugin
- How to build an API as a plugin
- Simple form that saves to database
- How to store ACF custom fields data in a custom table
- How to edit/delete single row items in a table on my own menu page
- Create or Update thousands of woocommerce products via PHP
- Get total number of comment of the posts written by an author
- How to write one comment and publish on every post using database or plugin?
- Make id column as AUTO INCREMENT on plugin activation
- wp_remote_get() returns 403 while file_get_contents() does not
- Creating a CSV with PHP inside the plugin directory
- How to pass the API key to the client from the database? [closed]
- Issue running db create table query from static method
- Integrating boxtal PHP library into a custom WordPress Plugin
- How to create plugin/ page that reads from database
- Api external with wordpress
- Comment “like” problem – “users who like this” avatar linking to current user profile instead of “liker’s” profile
- Is this plugin safe to run?
- How to display results from a data table with an encrypted user id?
- add_action for publish_post doesn’t work
- Getting URL GET parameter with Code snippets and storing it in database?
- How to convert Currency from USD to other IP Based currency in Php function
- How do I display PHP file contents on front end of WordPress?
- Push Contact form 7 variable to front end after submission
- Cant create table on plugin activation
- How to use WordPress header function and footer function and not load word press database
- Get Shortcode output to database for static post_content
- Moving a few select DB tables to a new WP instance
- How can I store user preferences in WordPress and retreive them later?
- How to save information related to post in database?
- cURL External API request displays content above other content on page
- plugin doesn’t retrieve data from database
- How do I show data from gravity forms in my template? [closed]
- How to make sense of the active_plugins option_value to enable and disable certain plugins from the database?
- Updating WordPress – the best approach (updating wp core, plugins and db)
- Bad Request (Invalid Hostname) on working server, database problem
- Plugin Not Working, But Only On GoDaddy Hosted site
- Errors while using ajax from external wordpress page
- Setting up widgets in wordpress with a unique ID for the after_title argument
- post expire after x days
- allow arabic letters when register new account
- How to get all events from ‘All in one Events calender’ plugin in JSON format?
- cURL error 60: SSL certificate problem: unable to get local issuer certificate
- How to Replace Words with Hypertext Link But Ignore Previously Existed Links?
- Make specific products accessible only to a user role in WooCommerce
- Building an email signup form. Where should the information be saved in the DB?
- Custom form action to handle data inside a plugin
- WP Post Template – Templates in own folder
- How to sanitize uploaded file filename from a plugin?
- Using WP Category Lists Plugin to Dynamically Display Category (PHP)
- Set and access global variable
- How to get the element ID from new menu list that added with add_filter()?
- Replacing a plugin function with a custom renamed function doesn’t work
- How to output CMB2 select options from repeated groups select elements?
- Delete query not working in plugin
- How do I network enable a plugin for a multisite install via the database?
- How to deal with WordPress and Pocket API to automate content curation on my hosted wordpress blog? [closed]
- How to disable search as you type plugin suggestions?
- WP All Import – Execute Imports
- External RSS feed to WordPress Portfolio
- Create Gallery using Custom Post Type and add sum gallery as sub gallery of Main Gallery
- Notify comment author upon reply
- WordPress get_avatar function not correct working
- How to show the number of website visitors in my theme
- Building a REST API for your web app exposes primary keys of DB records?
- How to make a dynamic css class whose name changes every visit to confuse scraper
- Assign all Post in Wp to a specific Category
- How to display registered customer list as dropdown in WooCommerce checkout?
- Error When Trying To Login [closed]
- Echo out element to another page.
- i need to make custom cron_schedule with custom interval time as a parameter into a custom payment gateway plugin wordpress
- Redirect unloggedin users
- Custom fields not showing up in the user info (PaidMembershipsPro)
- WP Function does not trigger on Webhook API Call
- Cookie value changes back to previous value after changing
- Problem with checked box on wp car manager plugin
- Performing CRUD operations on front end in wordpress
- issue concerning ob_end_flush functions.php
- In a plugin, How to update a json file using ajax
- How to add specific script to WordPress webpage that will working with user input and databases
- Can you add a shortcode to a custom post type that gets the post_title, post_content, etc. and then passes that to a plugin function?
- wp-admin/admin-ajax.php 400 (Bad Request) plugin
- How to echo a PHP Code After the Content
- Woocommerce list variations that are added already to cart in Single Product
- How to find out programmatically whether any cache plugin is installed in the WordPress website?
- Show custom taxonomy in theme
- errno: 150 “Foreign key constraint is incorrectly formed” [closed]
- Update (a function) post’s featured image as soon as $image_url changes
- Social sharing plugin directing to blank page after post sharing
- using href when creating wordpress plugin calls empty page instead of php file
- Media Playlist Plugin
- Saving custom form fields
- How to add php stylesheet to admin section instead of admin_head hook
- Posts are deleted everyday at night
- Display Plugin information on specific url
- Replace Dash (-) and Underscore ( _ ) with Space
- How use Dynamic hyperlink on each wordpress post?
- WordPress create permalink structure for custom post type with userid
- Function not being called on form submit, only blank admin-post.php page
- WordPress Convert queries to slashes using function.php