Skip to content
Read For Learn
Read For Learn
  • Database
    • Oracle
    • SQL
  • C
  • C++
  • Java
  • Java Script
  • jQuery
  • PHP
Read For Learn
  • Database
    • Oracle
    • SQL
  • C
  • C++
  • Java
  • Java Script
  • jQuery
  • PHP

Custom Post Type not showing anything added by code anymore?

It wasn’t working because at public status draft/publish were written without a capitol so it has to be 'post_status' => 'Draft' or 'post_status' => 'Publish'

Related Posts:

  1. Why WordPress choose data serialization over json_encode?
  2. Issue with wp_insert_post and post_content field error Could not update post in the database
  3. Dealing with Many Meta Values, 30+
  4. What is the most secure way to store post meta data in WP?
  5. How to delete outdated, wrongly sized images in _wp_attachment_metadata?
  6. Meta query interfering with orderby relevance
  7. Migrating non-WordPress CMS to WordPress, lots of data to move — possible solutions?
  8. How to solve slow WordPress site caused by attachment_metadata
  9. Can’t update database after wordpress update from 3.8.1 to 4.4.1
  10. Delete all post meta except featured image
  11. Add search Value to wp_list_table pagination
  12. Using table lock with wp_insert_post?
  13. Why are no posts showing despite my apparently correct DB restoration?
  14. Is it possible to store visitors IPs in wp_postmeta table?
  15. Multiple postmeta with same name for one post in wp_postmeta table
  16. Delete all post meta except featured image Using SQL
  17. One post carries 30 postmeta values, is this too much?
  18. delete post meta from db, even if does not exist?
  19. WordPress and MySQL: how to transfer Meta_key and Meta_Value from one post_id to another
  20. Storing data for a wordpress plugin
  21. Where does the actual data stored by add_post_meta
  22. Structure of postmeta meta_value for woocommerce product download
  23. Insert post in another database
  24. Routine to convert custom post meta from old to new value
  25. Retrieve data from the database to table such as comments in the admin control panel
  26. Saving zero as meta value
  27. Uknown meta entries in wp_postmeta
  28. How to combine multiple wp_insert_post into one in order to gain better performance
  29. Does post_meta data need to be unserialzed?
  30. Adding prefix to WordPress database tables breaks admin capabilities?
  31. Is my way to change WordPress server is correct?
  32. Link image with data from the wpdb
  33. Compare User meta_value with Product meta_value
  34. How to save EXIF metadata in WordPress database?
  35. _wp_attachment_metadata is not being added to database when PDF files uploaded
  36. “BS_” rows in postmeta table
  37. Migrating meta_key and meta_value from old theme to new one
  38. WordPress site migration – locked out of admin area
  39. WordPress Migration – Issue with admin panel changes
  40. Database structure for thousands of posts
  41. WordPress URL error for links
  42. How much post meta data is too much?
  43. Call to a member function insert()
  44. How do i get value from wp_postmeta?
  45. add_post_meta displays in admin edit area
  46. Recommended Post Structure for DB Storage
  47. SQL query : Select a thumbnail for a media
  48. Recover Same WordPress Admin Password
  49. cannot access wp-admin after options table crash and repair
  50. Database Queries are crashing the server
  51. How to protect my credentials on my clients website
  52. wp_update_post function exclude specific field
  53. large number (bigint) for post ID issue in database
  54. WordPress Admin login problems- PLEASE HELP [closed]
  55. What is an ORM, how does it work, and how should I use one? [closed]
  56. What is the difference between an ORM and an ODM?
  57. What is this JavaScript “require”?
  58. Rename a table in MySQL
  59. How should I tackle –secure-file-priv in MySQL?
  60. What is this JavaScript “require”?
  61. What is “Advanced” SQL?
  62. What’s the difference between identifying and non-identifying relationships?
  63. Can’t connect to MySQL server on ‘127.0.0.1’ (10061) (2003)
  64. Can’t connect to MySQL server on ‘127.0.0.1’ (10061) (2003)
  65. Can’t connect to MySQL server on ‘127.0.0.1’ (10061) (2003)
  66. What are the differences between B trees and B+ trees?
  67. MySQL SELECT increment counter
  68. How to resolve ORA-011033: ORACLE initialization or shutdown in progress
  69. Example of a strong and weak entity types
  70. Oracle SQL query for Date format
  71. phpMyAdmin – Error > Incorrect format parameter?
  72. Strange Characters in database text: Ã, Ã, ¢, â‚ €,
  73. Difference between partition key, composite key and clustering key in Cassandra?
  74. How SID is different from Service name in Oracle tnsnames.ora
  75. What is a relation in database terminology?
  76. Failed to connect to mysql at 127.0.0.1:3306 with user root access denied for user ‘root’@’localhost'(using password:YES)
  77. Database vs File system storage
  78. Can I have multiple primary keys in a single table?
  79. Exclude Statement in SQL
  80. How do you query for “is not null” in Mongo?
  81. What is a file based database?
  82. Is it fine to have foreign key as primary key?
  83. Storing Images in DB – Yea or Nay?
  84. Using wpdb to connect to a separate database
  85. how to Optimize WordPress database for 10 million post? [duplicate]
  86. MySQL Database User: Which Privileges are needed?
  87. Why is my database import losing text widget data?
  88. Database synchronization between dev/staging and production
  89. Keeping WP database synced across multiple developers using git
  90. Post meta vs separate database tables
  91. How to update custom fields using the wp_insert_post() function?
  92. WPDB Insert or if exists Update
  93. Multiple developers / editors working on a site in progress
  94. Attaching taxonomy data to post with wp_insert_post
  95. How can I make updates to a site, on a development copy, but then move updates back without overriding live site’s evolving database?
  96. get_results using wpdb
  97. Will it break my site if I delete all transient records in wp_options table?
  98. Checking if Database Table exists
  99. What’s the simplest way to backup my WordPress database?
  100. WordPress (MyISAM) database is slow, should I switch to InnoDB?
Categories Database Tags database, post-meta, wp-admin, wp-insert-post
Using WP meta query to show custom post types by a start and finish date
VServer/Rootserver/Shared Hosting: Multiple WordPress installations each having their unique domain?

Recommended Hostings

Cloudways: Realize Your Website's Potential With Flexible & Affordable Hosting. 24/7/365 Support, Managed Security, Automated Backups, and 24/7 Real-time Monitoring.

FastComet: Fast SSD Hosting, Free Migration, Hack-Free Security, 24/7 Super Fast Support, 45 Day Money Back Guarantee.

Recent Added Topics

  • Bug in translation system: load_theme_textdomain() returns true, files are available and accessible but the language defaults to english
  • Post Navigation Elementor
  • Custom Elementor controls not appearing in the widget Advanced tab using injection hooks
  • WPFacet multiple loop displaying duplicate content
  • Get the name of the template/*html file used
  • Fix: WordPress.DB.PreparedSQL.NotPrepared Plugin Check (PCP)
  • Removing unnecessary CSS and JS code from wp_head()
  • hexagonal image gallery. Am I on the right track? [closed]
  • Trying to Add Paging to Single Post Page
  • Sharing media files between live and staging servers
© 2026 Read For Learn
  • Database
    • Oracle
    • SQL
  • algorithm
  • asp.net
  • assembly
  • binary
  • c#
  • Git
  • hex
  • HTML
  • iOS
  • language angnostic
  • math
  • matlab
  • Tips & Trick
  • Tools
  • windows
  • C
  • C++
  • Java
  • javascript
  • Python
  • R
  • Java Script
  • jQuery
  • PHP
  • WordPress