We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 30223
    • 1,010 Posts
    I don’t know the chunky class but as far as PHx is concerned I have no plans in supporting it in eForm myself. If I understand correctly some of that functionality will be incorporated into the MODx core anyway using modInputFilter and modOutputFilter.

    Regarding internationalizing the templates. I’d think you could do this without to much coding using a the eFormonBeforeParse event.

      • 7455
      • 2,204 Posts
      The way I use phx in eform is insite chunks that way the eform parsor does not remove t he phx tag.
        follow me on twitter: @dimmy01
        • 37272
        • 216 Posts
        Hi,

        Why does the snippet call use:
          &subject=`Web site feedback`

        ?

        I understand that I can change that to whatever value I desire, but is it possible to use the subjects (options) from the eFeedBackForm as the subject? I have mail forwarded a the moment, and being able to identify mail by subject would be useful. I tried:
        &subject=`[+subject+]`

        but that failed.

        Additionally, I’d like to have two areas to the feedback form. The first dealing with common questions that could make use of replies from an auto responder; a second for other questions and feedback. I’d like these to be separate dropdown lists though. Also, would it be possible to have the option of them creating their own subject line? Any help would be appreciated.

        Have many people received spam through eForm? I had a couple yesterday, and the URLs contained long random strings of characters (which suggests to me they we created by a spambot with a unique URL to identify me if I was stupid enough to check out the link). Is there a hole in the CAPTCHA code?

        Thanks.


        Edit: I’m still using 1.41, so I’ll upgrade that. From the little reading I’ve done, it appears that support multiple forms on a single page - hopefully that will reolve the question about having two sections: one for auto-responder mail; one for other mail.
          • 30223
          • 1,010 Posts
          Upgrading is a good idea smiley

          If you have an input field named ’subject’ in your form you can simply leave out the &subject parameter. eForm will then use the input field as the email subject. Otherwise the parameter &subject=`[+subject+]` should work. If this doesn’t work check if you have the PHx plugin enabled. If so have a look in the PHx support forum. There’s a workaround for this.
            • 33273
            • 60 Posts
            Hi, Jelle!
            I’m trying to follow your instructions, but nothing.....
            I placed the functions you wrote in the snippet and called it before eForm (with &eformOnBeforeFormParse=`onBeforeParseFunction` &eFormOnBeforeMailSent=`getBanketPlace` parameters)

            And when I go to the page /contactform.html?place=Ontario I see blank page....
            eForm 1.4.3
            Please help.
              • 30223
              • 1,010 Posts
              There’s probably a typing or php error in the code.. Make sure you have error_reporting and display_errors {ini_set(display_errors)} on so you can see when a php error occurs.

              The function I wrote is to get you in the right direction. I can’t see anything obvious that’s wrong so you’ll have to experiment a bit. Does form work without those events for instance? Did you set the &debug parameter to see if that spits out anything useful? Good luck.
                • 37272
                • 216 Posts
                Quote from: TobyL at May 31, 2007, 02:23 AM

                Upgrading is a good idea smiley

                If you have an input field named ’subject’ in your form you can simply leave out the &subject parameter. eForm will then use the input field as the email subject. Otherwise the parameter &subject=`[+subject+]` should work. If this doesn’t work check if you have the PHx plugin enabled. If so have a look in the PHx support forum. There’s a workaround for this.

                Hi,

                What I’d like to have is a dropdown, as with the example code:

                <p><span style="color:#900;">[+validationmessage+]</span></p>
                <form method="post" action="[~[*id*]~]">
                    <input type="hidden" name="formid" value="feedbackForm" />
                    
                    <p><label accesskey="n" for="Name">Your Name</label>
                    <input type="text" name="Name" maxlength="60" eform="Your Name::1:Expected at least two words:#REGEX /\w+\b\w{2,}/i" /></p>
                
                    <p><label accesskey="e" for="email">Your Email Address</label>
                    <input type="text" name="email" size="40" maxlength="40" eform="Your Email Address:email:1" /></p>
                    
                    <p><label accesskey="s" for="department">Subject</label>
                    <select name="department">
                        <option value="1">Website feedback</option>
                        <option value="2">Support request</option>
                        <option value="3">Feature request</option>
                    </select></p>
                    
                    <p><label accesskey="c" for="comments">Comments</label>
                    <textarea cols="40" rows="10" name="comments" eform="Comments:html:1"></textarea></p>
                
                    <p>
                    Please enter the     anti spam code below:<br />
                    <img src="[+verimageurl+]" alt="verification code" border="1"/>
                    </p>
                    <p>
                    <label accesskey="c" for="vericode">code</label>
                    <input type="text" name="vericode" size="20" />
                    </p>
                    
                    <p><input type="submit" name="submit" value="Send Feedback"></p>
                </form>


                What I’d like is the subject chosen from the dropdown to be the subject of the e-mail. If I leave out the &subject parameter from the call, I end up with ’0’ as the subject. I’d use the dropdown to address common questions and have it replied to by the autoresponder. I’d like to have an option for the poster to create their own subject if a suitable subject is not available from the dropdown list, and they will receive a personalised e-mail.

                As far as I know I do not have the PHx plugin enabled. I’m still running 0.95, and no plugin by that name is listed. Where is the PHx forum you mentioned - I could not find it.

                Thanks.
                  • 30223
                  • 1,010 Posts
                  I’m sorry but what did you expect with the &subject=`[+subject+]` parameter? You don’t have a field in your form called subject!! You have a dropdown field with the label "subject" but with a field called ’department’ (with values 0,1,2...) This will hardly bring you any closer to having a sensible subject in your email...
                    • 27376
                    • 576 Posts
                    As TobyL stated, try changing [tt]&subject=`[+subject+]`[/tt] to [tt]&subject=`[+department+]`[/tt]. Then the department field will contain the numerical values.

                    To change this, change the values to the innerHTML of the option tags.
                    <select name="department">
                            <option value="Website feedback">Website feedback</option>
                            <option value="Support request">Support request</option>
                            <option value="Feature request">Feature request</option>
                    </select>
                      • 37272
                      • 216 Posts
                      Hi Thanks,

                      Obviously I cannot code at all. I had gotten as far changing ’subject’ for ’department’, and the subject line changed then to ’1’. I failed to understand that I needed to change the values of the options - I’ve never even created a form a before.

                      Thanks, this is working fine now. I now just need to add the option for people to create their own subject if none from the drop down are suitable. I’ll have good go at working that out for myself. wink

                      Thanks.

                      This discussion is closed to further replies. Keep calm and carry on.