41 reputation
6
bio website
location
age
visits member for 2 years
seen 2 days ago

Nov
21
comment attach image from library to post with wp_insert_attachment
I finally got it working by attaching from my desktop instead of the media library.
Nov
21
comment attach image from library to post with wp_insert_attachment
It's not already attached because these images are just added to the library. The posts have no images. I intend to batch attach a bunch but was testing with one first.
Nov
20
asked attach image from library to post with wp_insert_attachment
Nov
7
comment Customize search results to include custom posts and display in a specific template page
I need the 3 post types search results to display seamlessly on the same page in a very specific style (carousel) under that pages content.
Nov
7
revised Customize search results to include custom posts and display in a specific template page
update on my attempts
Nov
7
revised Customize search results to include custom posts and display in a specific template page
re-tried some code, updating
Nov
5
accepted Function/filter or plugin to change post status based on custom field value
Nov
5
revised Function/filter or plugin to change post status based on custom field value
including my final answer
Nov
5
comment Function/filter or plugin to change post status based on custom field value
I didn't have a lot of luck with this initially, made all my posts pending and then back again to published. What I ended up doing was echoing out all the unapproved ids based on the meta info and then using wp_update_post on that array to change them to pending. Not the best solution probably but it worked. Final code above in original question. Accepting your answer also as it does in fact work.
Nov
5
revised Customize search results to include custom posts and display in a specific template page
edited title
Nov
5
revised Customize search results to include custom posts and display in a specific template page
clarification
Nov
5
revised Customize search results to include custom posts and display in a specific template page
clarification
Nov
5
revised Customize search results to include custom posts and display in a specific template page
clarification
Nov
5
asked Customize search results to include custom posts and display in a specific template page
Oct
27
accepted wp_update_post question on array
Oct
27
asked wp_update_post question on array
Oct
26
comment Function/filter or plugin to change post status based on custom field value
Thanks for your response, but no luck with that. I tried it both ways and tried with other loops on index.php removed, so only that remained, reloaded and nothing happened. Any ideas why?
Oct
26
comment Function/filter or plugin to change post status based on custom field value
It's for posts that are already in the database only, so it will be a one-time thing to set to pending posts that have a custom field with a certain value. With new posts going forward I won't have this value.
Oct
26
asked Function/filter or plugin to change post status based on custom field value
Oct
26
revised Search result count not matching actual result
added 93 characters in body