Support » Plugin: Postie » Is that possible?

  • Resolved rabox66


    I am coding a tool where users can send information to wp, and admins can decide it that should be published as a post. That works like a charm with postie, but I have one problem: There is a <date> field that should be stored in a custom field.

    Why that? I need the data in a custom field in order to use it for sorting a query by date. (Not the date of sending or publishing. It is another date.)

    Is there any possibility of doing something like that? If you just give me some ideas, I will code it myself. But now I do not have a glue. I can retrieve the content of the <date> field by jQuery. But then I will need a serverside script to bring it into the database. If you know any workaround/link/ tutorial for that problem, please let me know. I would be glad!


    • This topic was modified 9 months ago by rabox66.
Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Wayne Allen


    Yes you can do that. Postie has several filter that can be used. Most likely you will want to use postie_post_before if you want to modify the message or you can use postie_post_after
    You will need to do this in PHP on the server rather than javascript on the client.

    Hello Wayne,
    thank you for the answer. That sounds pretty good, I think I can do that.

    Another question: The form also contains a <select> for choosing between different options. I want to use the chosen option as a category. That might be a bit tricky, what you think?

    The first problem is how to target the <select>. Then I have to retrieve the content, and then I have to use it as a category. Do you have any ideas how to do that? (It is not necaissairy to post the complete code here. Just some ideas how to make that working would be fine. (If possible without research.)

    Thank you!

    • This reply was modified 8 months, 3 weeks ago by rabox66.
    Plugin Author Wayne Allen


    It seems like there are a bunch of assumptions that you aren’t communicating. What form? What select? Are the emails free form or coming from another program?

    What you’re apparently describing is way outside the scope of Postie. Sounds like you’re talking about custom admin pages or at least theme customization.

    Sorry, you are right. I will explasin more in detail:
    I am using Contact Form 7 forms in a wordpress page. Users can fill in the cf7 form, the content the users fill in, is sent by email and Postie to WordPress in order to be turned into a post. That works perfectly now. Thanks a lot.

    One of my challenges is now, that the Contact Form 7 form uses a <select> with a bunch of options The loptions are lets say – category1, category2 and category3. What I want is, that the option the user chooses is used as a category for the post.

    Off cours the categories that are available witihn the wordpress installation and the options that are stored in the <select> are identical. So: if I a user chooses – lets imagine – the option “category2” the post should be published within category2.

    I suppose the filter postie_category has to be used for doing this. (?)

    Thank you

    Plugin Author Wayne Allen


    Yes that can be done through the filter. If you have the option you can also provide the category in the subject line as described in

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Is that possible?’ is closed to new replies.