• I am adding a dropdown field to the form via shortcode which eventually will be populated from custom posts. currently it’s just dummy code:

    function msug_wpcf7_instrumente_listgenerator() {
        /* need to produce html like this:
        <span class="wpcf7-form-control-wrap menu-645"><select name="menu-645" class="wpcf7-select"><option value="one">one</option><option value="two">two</option></select></span>
        so here we go:     */
        $instrumentelist = "<span class=\"wpcf7-form-control-wrap menu-instruments\"><select name=\"menu-instruments\" class=\"wpcf7-select\"><option value=\"test1\">test-1</option><option value=\"test2\">test-2</option></select></span>";
        return $instrumentelist;
    }
    wpcf7_add_shortcode('msug_wpcf7_instrumente', 'msug_wpcf7_instrumente_listgenerator');

    and coinsequently I add [msug_wpcf7_instrumente] to the form which displays properly.

    however, the field does not get inserted into the database (while all other “normal” fields do get inserted).

    any advice on this?

    http://wordpress.org/extend/plugins/contact-form-7-to-database-extension/

Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Plugin: Contact Form 7 to Database Extension] form fields added via wpcf7_add_shortcode hook not ad’ is closed to new replies.