If you plan to use wordpress as an aggregator of some sort, you'll need to learn how to post automatically with PHP. It's actually fairly simple to get started. Wordpress has the post function listed, so I will just basically copy and paste their code below:
// include the wordpress classes
include("wp-blog-header.php");
// Create post object
$my_post = array();
$my_post['post_title'] = 'My post';
$my_post['post_content'] = 'This is my post.';
$my_post['post_status'] = 'publish';
$my_post['post_author'] = 1;
$my_post['post_category'] = array(8,39);
// Insert the post into the database
wp_insert_post( $my_post );
// That's it!
As you can see, names are numbered, as are categories. That can make things tricky when you want to make it look like you have 10 users posting to 15 different categories. Now let's say you have additional custom fields you need to add. How the heck does that work? I'm glad I asked myself. . .
// include the wordpress classes
include("wp-blog-header.php");
update_post_meta(ID, 'image', 'imageurl_goes_here');
This is an example of adding an image to the post based on the post ID. You can add as many meta posts to each post as you wish.
Again, this is the simpliest way to automate posting, like adding an excerpt to each post. There are lots more things that can be customized in each post submission.
Similar Blogs:
AimStats 2.0 And Then Some
Too Much Time On My Hands
blog comments powered by Disqus
Blog Posts
- The Sad Truth About SEOBook
- Firefox Had Its Chance, It's Time For Google Chrome
- Cancel Your FreeCreditReport.com Account Without Calling
- Automate Wordpress Posting
- MySQL, How To SUM Time Correctly
« Previous
Recent Popular Posts
Most Commented Blog Posts
- Nintendo Wii Sucks (228)
- Microsoft Windows Search Indexer Stopped Working (32)
- GMX Mail Review (31)
- Windows Vista And Windows 7 0x80070017 Error (16)
- How To Block Ad-Brite Transition Ads (14)
