0
votes
1answer
101 views

Action hook “wp_insert_post” works but not for last imported post

I want to run a custom function whenever posts are imported to my custom post type. I am currently running this code - function on_post_import($post){ global $wpdb; $results = ...
0
votes
1answer
281 views

Insert two row in wordpress database

Hello I am working on a template where I have to grab some value and insert them in my own created table in wordpress database. Now as I dont know how to insert record in wordpress database , so i am ...
1
vote
1answer
265 views

Creating a post from data returned from HTML form

I am trying to write a WordPress plugin and I have hit a bump. The Background: I have some data in a mySQL DB that I am using (each row has a unique ID and some other information I have added). I am ...
0
votes
1answer
181 views

Plugin to create Posts and Forums then choose category and parent forum

I need to create a plugin for a customer that will help him create posts and forums and place them in a category and choose if it's a parent or a child forum. Just created a GitHub Repo for my files ...
1
vote
1answer
741 views

using $wpdb to insert a form into a post

I am wanting to take the following form, and use $wpdb to insert it into a post. I have tried reading the class reference page INSERT rows, but I don't really know what should be referenced. I am not ...
1
vote
1answer
816 views

Programmatically Creating Page using $wpdb and getting 404 error

EDIT: Turns out I had a permalink issue that was causing the 404 error. Original Posting below: I am creating a page programmatically using $wpdb->insert() and the resulting page returns a 404 ...