WordPress.org

Support

Support » Plugins and Hacks » [Plugin: Contact Form 7] Custom Value for Selects

[Plugin: Contact Form 7] Custom Value for Selects

  • This plugin (contact form 7) is one of my favorite plugins. Extremely simple and robust at the same time. The generate tag thing is perfect.

    I was hoping to be able to add a custom value to a select.

    Example:
    Here’s a select tag:

    [select section "option1" "number2" "idea3"]

    This spits out:

    <select name="section">
    <option value="option1">option1</option>
    <option value="number2">number2</option>
    <option value="idea3">idea3</option>
    </select>

    I need the values to be different than what is displayed, so something like this:

    <select name="section">
    <option value="ab">option1</option>
    <option value="123">number2</option>
    <option value="asd">idea3</option>
    </select>

    I’m trying to just copy the code it spits out and then editing it, but it seems to check that =(

    Thanks again for the excellent plugin.

    Ashton Sanders

Viewing 1 replies (of 1 total)
  • I have a quick hack:

    In the above example, I created the select tag as:
    [select section “ab” “123” “asd”]

    Then I copied the HTML it outputs, and used that as the code on the page. Then I edited the display value to be the same as above. This got it past the validation.

    It would be nice to have this as part of the plugin though 😉

    Thanks,

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Contact Form 7] Custom Value for Selects’ is closed to new replies.
Skip to toolbar