We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 42503
    • 120 Posts
    Yes I written the same code with capital OS. But still the problem is same.Quote from: donquicky at Jul 23, 2013, 07:27 AM
    Your values of the select options are with starting capitals. Change the code in tplSelectOS like:
    [[+OS:is=`Linux`:then=`[[$tplLinux]]`]]
    [[+OS:is=`Windows`:then=`[[$tplWindows]]`]]
    [[+OS:is=`MacOS`:then=`[[$tplMacOS]]`]]
    [[+OS:is=`Novatel`:then=`[[$tplNovatel]]`]]
      • 42503
      • 120 Posts
      I have tried all the combination but still the result is same. Please help.Quote from: pronab.saha at Jul 23, 2013, 07:30 AM
      Yes I written the same code with capital OS. But still the problem is same.Quote from: donquicky at Jul 23, 2013, 07:27 AM
      Your values of the select options are with starting capitals. Change the code in tplSelectOS like:
      [[+OS:is=`Linux`:then=`[[$tplLinux]]`]]
      [[+OS:is=`Windows`:then=`[[$tplWindows]]`]]
      [[+OS:is=`MacOS`:then=`[[$tplMacOS]]`]]
      [[+OS:is=`Novatel`:then=`[[$tplNovatel]]`]]
        • 37105
        • 194 Posts
        What is the exact output you get?
          Codeplaza Webdesign: for professional websites at low cost
          • 42503
          • 120 Posts
          This is output I am getting now. I have selected Novel so it is now rendering the text for Novel but with other 3 together.

          [[+OS:is=`Linux`:then=`this is for linux`]] [[+OS:is=`Windows`:then=`This is for windows`]] [[+OS:is=`MacOS`:then=`This is for Mac OS.`]] This is for Novel

          Quote from: donquicky at Jul 23, 2013, 08:17 AM
          What is the exact output you get?
            • 37105
            • 194 Posts
            Can you show the content of chunk tplSelectOS ?
              Codeplaza Webdesign: for professional websites at low cost
              • 42503
              • 120 Posts
              [[+OS:is=`Linux`:then=`[[$tplLinux]]`]]
              [[+OS:is=`Windows`:then=`[[$tplWindows]]`]]
              [[+OS:is=`MacOS`:then=`[[$tplMacOS]]`]]
              [[+OS:is=`Novel`:then=`[[$tplNovel]]`]]

              Quote from: donquicky at Jul 23, 2013, 08:36 AM
              Can you show the content of chunk tplSelectOS ?
                • 37105
                • 194 Posts
                Strange, it works on my testmachine. Just to be sure: what is the exact name of chunk for Novel you created? tplNovatel or tplNovel?

                Created 4 chunks tplLinux, tplWindows, tplMacOS and tplNovatel

                It looks like a typo somewhere ...
                  Codeplaza Webdesign: for professional websites at low cost
                  • 42503
                  • 120 Posts
                  Yes at first it was a typo but basically spelling is Noval, I have updated through out the form.

                  I am sent you all the code I have written for this form.

                  [[!FormIt?
                  &hooks=`recaptcha,spam,FormSave,email,redirect,FormItAutoResponder`
                  &emailTpl=`trial_report` 
                  &emailSubject=`Trial Form - [[+name]]` 
                  &emailTo=`[email protected]`
                  &redirectTo=`91`
                  &fsFormTopic=`contact`
                  &recaptchaTheme=`white`
                  &fiarTpl=`tplSelectOS`
                  &fiarSubject=`Thank You for Contacting Us`
                  &fiarToField=`email`
                  &fiarFromName=`Learn MODx Website`
                  ]]
                  
                  
                  
                  
                  
                  
                  <div class="contentCol2_form_home">
                  <form id="enquiry-form1" action="[[~[[*id]]]]" method="post">
                  <input type="text" name="name" id="name" class="txtBox" value="[[!+fi.name]]" title="Name" />
                  <input type="text" name="company" id="company" class="txtBox" value="[[!+fi.company]]" title="Company" />
                  <input type="text" name="phone" id="phone" class="txtBox" value="[[!+fi.phone]]" title="Phone Number" />
                  <input type="text" name="email" id="email" class="txtBox" value="[[!+fi.email]]" title="Email" />
                      <select name="hearabout" class="menuList">
                        <option>How did you hear about us?</option>
                        <option value="Radio" [[!+fi.hearabout:FormItIsSelected=`Radio`]] >Radio</option>
                        <option value="TV" [[!+fi.hearabout:FormItIsSelected=`TV`]] >TV</option>
                        <option value="Internet" [[!+fi.hearabout:FormItIsSelected=`Internet`]] >Internet</option>
                        <option value="Newspaper" [[!+fi.hearabout:FormItIsSelected=`Newspaper`]] >Newspaper</option>
                        <option value="Other" [[!+fi.hearabout:FormItIsSelected=`Other`]] >Other</option>
                      </select>
                      <select name="OS" value="[[!+fi.OS]]" class="menuList">
                        <option>Select Operating System</option>
                        <option value="Windows" [[!+fi.OS:FormItIsSelected=`Windows`]] >Windows</option>
                        <option value="MacOS" [[!+fi.OS:FormItIsSelected=`MacOS`]] >Mac OS</option>
                        <option value="Linux" [[!+fi.OS:FormItIsSelected=`Linux`]] >Linux</option>
                        <option value="Novel" [[!+fi.OS:FormItIsSelected=`Novel`]] >Novel</option>
                      </select>
                      <p>
                      <input type="checkbox" name="newsletters" value="newsletters" [[!+fi.color:FormItIsChecked=`newsletters`]] > Keep me updated through newsletters 
                      </p>
                      [[+formit.recaptcha_html]]
                  	[[!+fi.error.recaptcha]]
                      <p>
                      <input type="checkbox" name="accept" value="accept" [[!+fi.color:FormItIsChecked=`accept`]] > accept the <a href="#">terms</a>
                      
                      <input name="btn" type="submit" value="Sign Up" class="submitBtn" /></p>
                  </form>
                    </div>
                  


                  tplSelectOS --
                  [[+OS:is=`Linux`:then=`[[$tplLinux]]`]]
                  [[+OS:is=`Windows`:then=`[[$tplWindows]]`]]
                  [[+OS:is=`MacOS`:then=`[[$tplMacOS]]`]]
                  [[+OS:is=`Novel`:then=`[[$tplNovel]]`]]



                  Thank you

                  Regards,
                  Pronab

                  Quote from: donquicky at Jul 23, 2013, 09:06 AM
                  Strange, it works on my testmachine. Just to be sure: what is the exact name of chunk for Novel you created? tplNovatel or tplNovel?

                  Created 4 chunks tplLinux, tplWindows, tplMacOS and tplNovatel

                  It looks like a typo somewhere ...
                    • 37105
                    • 194 Posts
                    Very strange, with your code on my test MODX it renders just fine without any errors. There is one difference: I don't use Recaptcha or FormSave in my configuration so I deleted that part of your code. Cause?
                      Codeplaza Webdesign: for professional websites at low cost
                      • 42503
                      • 120 Posts
                      Hi Donquicky,
                      Yes, its really strange. I have removed capcha and formsave but still the result is same. My bad luck. In the meantime if you find any solution to this code please let me know.

                      Thank you

                      Regards,
                      Pronab

                      Quote from: donquicky at Jul 23, 2013, 10:02 AM
                      Very strange, with your code on my test MODX it renders just fine without any errors. There is one difference: I don't use Recaptcha or FormSave in my configuration so I deleted that part of your code. Cause?