Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Hay Guys , I'm currently making a plugin so that the administrator can manage "Subscriptions" to the website. I have made a custom post type and activated it within WordPress and only allowed the title field. This works perfectly on the backend, but now i need a way for front end users to add their email address.

How would i implement this, i need to add data to the database, i could easily just write some PHP to manually add the data, but does WordPress have any calls so that i can save data to the database?

share|improve this question
    
not particularly clear what you're trying to do. is there any reason your users can't use the email field in their WordPress profile? How is this related to your custom post type? –  anu Mar 31 '11 at 9:54
add comment

1 Answer 1

up vote 2 down vote accepted

Rake a look at wp_insert_post() which handles the insertion of new posts to the database.

and there are many example how to create posts from the front end here, here, here, here and here:

share|improve this answer
    
Perfect, thanks! –  dotty Mar 31 '11 at 11:21
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.