I'm having an issue with an EE2.11.6 site running Simple Registration 1.5.1.

We have a multi-field registration form on the site (using Simple Registration) and when a user fills in the form (and say they the form produces an error page saying username already taken etc) on reload of the form/registration page it wipes all the form data.

The form script is as follows:

{exp:simple_registration:form 
return='community{if segment_2}/{segment_2}{/if}' 
skip_success_message='y'
name="register"}    

    <div class="unit1 header">
        <h3>{membership_form_title}</h3>{!-- SNIPPET --}
        <p>{membership_form_text}</p>{!-- SNIPPET --}
    </div>

    <ul class="errorTxt"></ul>

    <div class="unit1">
        <div class="unit4">
            <p><label for="firstname"><strong>First name</strong></label></p>
        </div>
        <div class="unit3-4">
            <p><input type="text" name="firstname" id="firstname" /></p>
        </div>                  
    </div>


    <div class="unit1">
        <div class="unit4">
            <p><label for="lastname"><strong>Last name</strong></label></p>
        </div>
        <div class="unit3-4">
            <p><input type="text" name="lastname" id="lastname" /></p>
        </div>                  
    </div>  

    <div class="unit1">
        <div class="unit4">
            <p><label for="organisation"><strong>Organisation</strong></label></p>
        </div>
        <div class="unit3-4">
            <p><input type="text" name="organisation" id="organisation" /></p>
        </div>                  
    </div>                                              

    <div class="unit1">
        <div class="unit4">
            <p><label for="email"><strong>Email</strong></label></p>
        </div>
        <div class="unit3-4">
            <p><input type="text" name="email" id="email" /></p>
        </div>                  
    </div>  

    <div class="unit1">
        <div class="unit4">
            <p><label for="telephone"><strong>Telephone</strong></label></p>
        </div>
        <div class="unit3-4">
            <p><input type="text" name="telephone" id="telephone" /></p>
        </div>                  
    </div>  

    <div class="unit1">
        <div class="unit4">
            <p><label for="where-did-you-hear-about-us"><strong>Where Did You Hear About Us</strong></label></p>
        </div>
        <div class="unit3-4">
            {where-did-you-hear-field}
        </div>                  
    </div>  

    <div class="unit1">
        <div class="unit4">
            <p><label for="research-area"><strong>Area of interest</strong></label></p>
        </div>
        <div class="unit3-4">
            {research-area-field}
        </div>                  
    </div>  

    <div class="unit1">
        <div class="unit4">
            <p><label for="country"><strong>Country</strong></label></p>
        </div>
        <div class="unit3-4">
            {country-list}  
        </div>                  
    </div>                                      

    <div class="unit1">
        <div class="unit4">
            <p><label for="password"><strong>Password</strong></label></p>
        </div>
        <div class="unit3-4">
            <p><input type="password" name="password" id="password"/></p>
        </div>                  
    </div>  

    <div class="unit1">
        <div class="unit4">
            <p><label for="password_confirm"><strong>Confirm password</strong></label></p>
        </div>
        <div class="unit3-4">
            <p><input type="password" name="password_confirm" id="password_confirm"/></p>
        </div>                  
    </div>      

    <div class="unit1">

        <br />

        <div class="unit4">
        <p><label for="where-did-you-hear"></label></p>
        </div>

        <div class="unit3-4" style="font-size:.95em;line-height:150%;">

            We would like to keep you informed with the latest news, data and innovations from the neuroscience and clinical trial community. We'll always treat your contact information with great care and will never allow other companies to access your information for marketing purposes.

            <br /><br />

            Please let us know if you would like us to contact you or not by selecting one of the options below.

        </div>

        <div class="unit4">
        <p><label for="where-did-you-hear"></label></p>
        </div>
        <div class="unit3-4">
            <ul style="list-style:none; padding:0;" class="opt_in">
                <li>
                    <input name="opt-in" id="freeform_opt-in_1" value="yes" type="radio">
                    <label for="freeform_opt-in_1" style="color:#000">Yes please, I would like to stay up to date with the neuroscience research and clinical trial communities.</label>
                </li>
                <div class="clearfix"></div>
                <li>
                    <input name="opt-in" id="freeform_opt-in_2" value="no" type="radio">
                    <label for="freeform_opt-in_2" style="color:#000">No thanks, I don't want to hear about the latest news, scientific data and technology innovations.</label>
                </li>
            </ul>
        </div>

    </div>                  

    <div class="unit1">
        <div class="unit4">
            &nbsp;
        </div>
        <div class="unit3-4">
            <p>
                <input type="submit" class="submitButton" name="Submit" id="Submit" value="Submit" />                           
            </p>
        </div>                  
    </div>
{/exp:simple_registration:form}

If anyone has any ideas on this it would be a great help!

Many thanks in advance :-)

Regards

Karl

I think you should try by adding value="" attribute into template tags. So, it will keep your existing data into form as it is.

{exp:simple_registration:form return='community{if segment_2}/{segment_2}{/if}' skip_success_message='y' name="register"}
<div class="unit1 header">
    <h3>{membership_form_title}</h3>{!-- SNIPPET --}
    <p>{membership_form_text}</p>{!-- SNIPPET --}
</div>

<ul class="errorTxt"></ul>

<div class="unit1">
    <div class="unit4">
        <p><label for="firstname"><strong>First name</strong></label></p>
    </div>
    <div class="unit3-4">
        <p><input type="text" name="firstname" id="firstname" value="{firstname}" /></p>
    </div>                  
</div>

<div class="unit1">
    <div class="unit4">
        <p><label for="lastname"><strong>Last name</strong></label></p>
    </div>
    <div class="unit3-4">
        <p><input type="text" name="lastname" id="lastname" value="{lastname}" /></p>
    </div>                  
</div>  

<div class="unit1">
    <div class="unit4">
        <p><label for="organisation"><strong>Organisation</strong></label></p>
    </div>
    <div class="unit3-4">
        <p><input type="text" name="organisation" id="organisation" value="{organisation}" /></p>
    </div>                  
</div>                                              

<div class="unit1">
    <div class="unit4">
        <p><label for="email"><strong>Email</strong></label></p>
    </div>
    <div class="unit3-4">
        <p><input type="text" name="email" id="email" value="{email}" /></p>
    </div>                  
</div>  

<div class="unit1">
    <div class="unit4">
        <p><label for="telephone"><strong>Telephone</strong></label></p>
    </div>
    <div class="unit3-4">
        <p><input type="text" name="telephone" id="telephone" value="{telephone}" /></p>
    </div>                  
</div>  

<div class="unit1">
    <div class="unit4">
        <p><label for="where-did-you-hear-about-us"><strong>Where Did You Hear About Us</strong></label></p>
    </div>
    <div class="unit3-4">
        {where-did-you-hear-field}
    </div>                  
</div>  

<div class="unit1">
    <div class="unit4">
        <p><label for="research-area"><strong>Area of interest</strong></label></p>
    </div>
    <div class="unit3-4">
        {research-area-field}
    </div>                  
</div>  

<div class="unit1">
    <div class="unit4">
        <p><label for="country"><strong>Country</strong></label></p>
    </div>
    <div class="unit3-4">
        {country-list}  
    </div>                  
</div>                                      

<div class="unit1">
    <div class="unit4">
        <p><label for="password"><strong>Password</strong></label></p>
    </div>
    <div class="unit3-4">
        <p><input type="password" name="password" id="password"/></p>
    </div>                  
</div>  

<div class="unit1">
    <div class="unit4">
        <p><label for="password_confirm"><strong>Confirm password</strong></label></p>
    </div>
    <div class="unit3-4">
        <p><input type="password" name="password_confirm" id="password_confirm"/></p>
    </div>                  
</div>      

<div class="unit1">
    <br />
    <div class="unit4">
        <p><label for="where-did-you-hear"></label></p>
    </div>

    <div class="unit3-4" style="font-size:.95em;line-height:150%;">
        We would like to keep you informed with the latest news, data and innovations from the neuroscience and clinical trial community. We'll always treat your contact information with great care and will never allow other companies to access your information for marketing purposes.
        <br /><br />
        Please let us know if you would like us to contact you or not by selecting one of the options below.
    </div>

    <div class="unit4">
        <p><label for="where-did-you-hear"></label></p>
    </div>
    <div class="unit3-4">
        <ul style="list-style:none; padding:0;" class="opt_in">
            <li>
                <input name="opt-in" id="freeform_opt-in_1" value="yes" type="radio">
                <label for="freeform_opt-in_1" style="color:#000">Yes please, I would like to stay up to date with the neuroscience research and clinical trial communities.</label>
            </li>
            <div class="clearfix"></div>
            <li>
                <input name="opt-in" id="freeform_opt-in_2" value="no" type="radio">
                <label for="freeform_opt-in_2" style="color:#000">No thanks, I don't want to hear about the latest news, scientific data and technology innovations.</label>
            </li>
        </ul>
    </div>

</div>                  

<div class="unit1">
    <div class="unit4">
        &nbsp;
    </div>
    <div class="unit3-4">
        <p>
            <input type="submit" class="submitButton" name="Submit" id="Submit" value="Submit" />                           
        </p>
    </div>                  
</div>
{/exp:simple_registration:form}

Ideally it should works if plugin code follows EE standards. But I didn't use this plugin ever.

I suggest you to use Smart Members PRO plugin for Login and Registration. I am biggest fan of this plugin. It gives all necessary things in very simple way which requires to make member section(Login, Registration, Update profile, Forgot password, Reset-profile, Login with Social Media etc). It is the KING of Member section.

  • Hi Harsh, many thanks for feedback on this. Unfortunately the form is not using any form variables in the back end with the SR module (ie. it's a stock form wrapped in SR module tags). I did try it anyway but you inevitably end up with {firstname} {lastname} appearing in the relevant front end field areas. I could opt to use something other than Simple Registration, but the site has some additional plugin implementation that sends the form data off to a NetSuite API, so I'd rather not upset this configuration at this point by changing the module etc. But many thanks once again on this. – Karl Bowers Nov 5 at 12:57

Your Answer

 
discard

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.