WordPress.org

Ready to get started?Download WordPress

Forums

Contact Form 7
Loop Posts inside of Contact Form 7 (3 posts)

  1. bej-soan
    Member
    Posted 9 months ago #

    Hi,

    I'm trying to build an order form and have a question. I am quite familiar with loops, but not with mailer and contact forms, thats why I use this very handy plugin.

    My products are the post type. Now I want to have a form with the product listing inside to check/uncheck and other fields. I did not build something yet, but my idea is something like this (just idea, no real code)

    <form>
    <custom loop stuff - listing the products>
    <while have posts>
        <product>
        the_title()
        <img productimage>
        <input>choose size</input>
        </product>
    <endwhile>
    <input>adress stuff</input>
    <input>SEND</input>
    </form>

    Do you get what I mean? Is something like this possible? Can I custom rebuild the form so its working right or should I build a form completly on my own? Or is it possible the form is getting vars from fields outside itself?

    *EDIT* In Idea I just had: The Custom Post Loop can be set before the form and inside the form I execute the while. Possible solution? Is it possible to do a while inside the form?

    Thanks for the help

    http://wordpress.org/plugins/contact-form-7/

  2. biswajeet
    Member
    Posted 9 months ago #

    What will be the purpose of the order form you were trying to build?
    What action will be taken on form submitted? Will the form data need to be stored in DB or simply to send mail?

    One thing to mind is that you can't pre fill any CF7 field with data associated from product info. Additionally, you can't extend the CF7 form with custom fields from outside simply like you assumed as above.

  3. bej-soan
    Member
    Posted 9 months ago #

    Thanks for your answer.

    The Purpose is that the User sees a list of items with picture and can enter the amount he needs, his data and sends. It will be sent via E-Mail since the client has no automatic system in handling and is not planning in this direction right now. So the mail has the text field product-xyz 1xL 4xM 3S and so on.

    Of course I can build all the product fields manual in the form, but I wanted to maintain them via a custom post type automatically. If I can't find a solution it will be built manual.

Reply

You must log in to post.

About this Plugin

About this Topic