0
votes
1answer
15 views

What happens if I delete all the rows that represents a post revision from the posts table into WordPress database?

I have the following doubt related to the posts table of the WordPress database. I see that when I create a new post in this table are automatically created 2 new rows. 32 1 2014-08-16 15:07:22 ...
0
votes
0answers
7 views

Where is stored the Publish date value for a post?

I have to do a massive change in the database and I need to know in what field of what table is stored the publish date value of a post. Using phpMyAdmin I see that each record into the wp_posts ...
0
votes
1answer
113 views

Using radio button meta data from a custom meta box

Very new to attempting PHP and am hacking together my first plugin using tutorials.. I have a custom meta box with a Yes/No radio button on all WordPress pages (in the editor). EDIT- I removed the ...
0
votes
1answer
53 views

How to add an admin notice upon post save/update

I have a post type the uses post_save to take the address from the post-meta and retrieve the lat/lng coordinates from the Google API. I need a way of notifying the user if there was an issue with ...
0
votes
1answer
29 views

Get author posts count after excluding a category

I want to display the posts count of each author, but posts that are in some categories should be excluded from the count. I tried doing this with count_user_posts( $user->ID ), but this function ...
0
votes
0answers
46 views

Adding Attachment Display Settings in custom media frame

I made my own custom media frame : $('.add').bind('click', function(event) { event.preventDefault(); // Create the media frame. file_frame = wp.media.frames.file_frame = wp.media({ ...
0
votes
0answers
32 views

How to add links under every posts? ( WHILE BUILDING PLUGIN not manually )

I want to use, change, add and delete the links that appears with every posts. (e.g. May 21, 2014| 1 Comment) If I'm not wrong these are called template tags. I can play with them manually by getting ...
0
votes
1answer
79 views

How to get post bulk edit action trigger and get edited post ids?

I want to send email if a postmeta of a post is changed to the expected value.So previously i was doing loop to check the post meta in each post. In here am running the loop in admin_init hook. But ...
0
votes
1answer
55 views

What's an efficient way to change the post status of many posts at once?

I'm looking for an efficient way to change the post status on many posts at once. I have a custom post type that I'm using as a means to store content that must be approved by a moderator before being ...
0
votes
0answers
20 views

Stop post submission without losing data?

Is it possible to stop a post from publishing/updating, and instead redirect back to the post with the same data that was being submitted? I want to do this so I can show an error message, should ...
0
votes
0answers
155 views

Programmatically schedule post with wp_update_post function

I schedule posts in a wp plugin (WP 3.8) with the following function. My posts seem to be in the correct status after scheduling them (when editing them, date time and status are good), and also after ...
1
vote
1answer
42 views

Execute a plugin only on post pages

I am building a plugin that is only useful and should only run on pages where posts are featured. Is there a way to only run the plugin on pages that display posts?
0
votes
1answer
28 views

Cant' Grab WordPress Built-in Posts Through Loop

Using WordPress 3.7.1 I am trying to display all Regular Post on my created page lest say TestPage. Here are the steps I took to do this: 1- Generate a Custom Page Template called:Test Page and ...
0
votes
0answers
94 views

How to configure comments evolved for wordpress for pages?

I have installed Comments Evolved for WordPress to enable comments in my sites. there are so many pages and posts in my sites. i have activate this plugin succesfully. this plugin works fine with ...
0
votes
1answer
108 views

How can my plugin display a populated new post window

I've written a plugin that creates a feed reader like google reader in wordpress. Currently I let folks reblog feed items by using the built in WP PressThis plugin url. I pass in parameters and WP ...
1
vote
1answer
112 views

How use %like% in sql statement wordpress

i use a like %text% statement in wordpress: SELECT * FROM location WHERE name LIKE "%on" OR name LIKE "%on%" i tried anything but it's not run: $wpdb->get_results($wpdb -> prepare("SELECT ...
1
vote
1answer
194 views

Publish Post After Click On A Link

I have a frontend posting form (CF7), where user inputs (among other data of course) his email. Now I set the status to pending. What I want is, that the user would get trough autoresponder a mail, ...
0
votes
1answer
62 views

search content of pages and list in wp-admin

I am developing a plugin, and I want to display a page that lists every page on the site that is using a specific shortcode defined by my plugin. I assume that I need to manually search wp_posts, but ...
0
votes
0answers
52 views

Get page type to display content

I have some checkboxes to select where can I display my plugin and I save in db in this format: Show popup in this pages: x Article (Public) x Pages (Public) x File (Public) x Revisions (Not ...
0
votes
1answer
425 views

Delete data from custom table when deleting a post

I want to delete post id form my custom table, when deleting a post. I have tried this way, nothing happened. Please help. add_action('delete_post', 'delete_data'); function delete_data($post_id) { ...
0
votes
1answer
25 views

Finding a post's slug

I'm using wp_query() to get custom posts from the database. I want to list these out as links to the entries, so I'm thinking I could use the slugs. Sadly these don't seem to be included in the ...
0
votes
1answer
71 views

Capturing POST data

I am trying to modify the Member Status Plugin so that the status are based on the data saved on a custom database table. Basically I wanted to change the administration menu with a form that can ...
0
votes
2answers
176 views

wordpress remove views from action links in a custom post

I have created a custom post type, but I want to remove the View link from actions, in the listing of the custom post. I have tried this snippet add_filter( 'post_row_actions',array(&$this, ...
1
vote
1answer
37 views

How to store an extra (surrogate) ID when creating a post with wp_insert_post?

I am generating posts based on rows from a table on an existing database. If a row in the database gets updated I will have to update the respective post. The proble is that I have to find the post ...
0
votes
2answers
89 views

Plugin is creating posts twice

I have code which takes some $_POST data and loops through it. In the loop, I store the $_POST data in variables and create a new post using those variables. The loop ends when I run out of $_POST ...
0
votes
1answer
51 views

Insert specific information to a posts of a predefined category

I want to show some detail information on specific (for e.g. category=3) posts. Therefore I use the following coding: function postinfo_head() { global $post; $script = <<< EOF ...
5
votes
1answer
130 views

Listen to Post action

I am writing a plugin that adds a custom metabox to the post page. I would like to trigger an event when the user navigates away from the edit post page or when a user stops editing a specific post. ...
0
votes
1answer
3k views

Open a wordpress single post in a lightbox without the header and footer

I am developing a plugin which requires to open a single wordpress post inside of a lightbox. Here are a few details : Currently,I am using colorbox for lightbox. The lightbox is triggered to open ...
5
votes
2answers
373 views

Passing current cookies in wp_remote_get to get Draft Post Preview

I want pass current user cookies in wp_remote_get function to get a Draft Post Preview page content. I check already the questions: What URL do you pass to wp_remote_get to load the body of the ...
1
vote
1answer
121 views

which action to hook to in order to perform post-publish action

I have some functionality I've written in order to post the title and link for the post to twitter whenever a post is published. I'm wondering which wp function to hook this to? save_post has no real ...
1
vote
2answers
879 views

How to get posts by content?

I found the following codes to get post details. However, it is not possible to get the posts by content. Does any one has any ideas? get_posts() //// get post //// $args = array( 'numberposts' ...
0
votes
3answers
338 views

How can I show posts for a single category?

Is it possible to show posts for a single category? I tried browsing to the URL http://mysite.com/category/foo which does show all of the posts with category foo, but the posts lose their formatting ...
0
votes
1answer
60 views

my basic php code producing unexpected results

I am writing a code snippet to display attachments to a post but for each user, he should only be able to see his own attachments and not those of other users $current_user=wp_get_current_user(); ...
0
votes
3answers
344 views

Custom feed parameters / Template overriding

Am relatively new to Wordpress development and looking for the best way to customize the output for a specific javascript app that will be pulling in the content dynamically, by using a Wordpress ...
1
vote
1answer
507 views

get post attachment using ajax

I'm developing a plugin and I'm trying to get the url's from a post's attachments with ajax. If the user is on a single.php page. After some seconds, I'm sending an Ajax request, getting all the ...
0
votes
1answer
363 views

How to Show Category List With Corresponding Links?

i want to do a research in Category List Area. I'll Explain Here... Now I have 4 Categories Like 1,2,3,4. First of all it needs to show in the category pages Horizontally.Next is, While Clicking on ...
0
votes
3answers
3k views

How to get Recent Post From Each Category with Thumbnail?

For Example,Now I have 3 Categories Like Food,Transport,Technology.Under These Categories I have Many Posts.Now I Want To Show the Latest Post From Each Category.{How to get Recent Post From Each ...
2
votes
2answers
2k views

How to add option box in “Edit Post” plugin API?

This might be kind of simple, but I couldn't find a way to do so in the WP docs. My plugin currently uses custom fields for things I could just have radio buttons/check boxes for each post. How do I ...
1
vote
1answer
1k views

How to use WP default post list tables in a plugin?

I'm developping a plugin to manage a base of users and I'd like to show them in the same type of table used in other parts of the WP admin (post lists, user lists, etc.), I'd like to have the same ...
1
vote
1answer
101 views

finding whether request is for post, and post id

I need a hook such that when visitor lands on any of the post (not page), I need to record a hit. How can I find whether the request is for post, and is there any hook to find if the loaded content ...
4
votes
2answers
707 views

How can I make it so the Add New Post page has Visibility set to Private by default?

I'm trying to create a plugin that alters the Add New Post page so the Visibility field says "Private" by default: Status: Draft Visibility: **Private** Publish immediately [Publish] ...as opposed ...
0
votes
1answer
299 views

help intercepting save_post through plugin

I use stackoverflow very often and just found out in google about this one, Nice :D Well, i want to save my every post i write from wordpress to my 3rd (OEXChangeble) website aswell at the same time, ...