Explore the community Forums Lectora Lectora Questions & Answers Form Entry Not Detecting Chrome Auto-filled Content

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #384309 Score: 0
    Profile photo of Cam Phillips
    Cam Phillips
    Member
    beginner
    intermediate
    friend finder
    wise owl
    curious george
    contributor
    19 pts
    @_

    Hi Folks,

    I’ve got a page at the end of my course where a learner types their name into a form field, which is then passed as a variable to a piece of Javascript which generates a certificate of completion and embeds their name.

    This is all working well, but one of our users found that if they use Chrome’s autofill functionality (i.e. type ‘C’, click ‘Cam Phillips’ from the autocomplete dropdown to populate the field) that this data isn’t being logged to the Entry_0001 variable… so they would get a certificate with only ‘C’ (letters they actually entered on the keyboard).

    I see no option within Lectora to disable autofill – expected as this is governed by browser settings.

    Has anyone experienced this, or devised a workaround?

    Thanks in advance!

    Cam

    #384332 Score: 1
    Profile photo of Stan Miller
    Stan Miller
    Member
    beginner
    intermediate
    LUC16 Attendee
    wise owl
    contributor
    curious george
    friend finder
    LUC17 Attendee
    35 pts
    @smiller7502

    If you’re publishing to an LMS, try using the variable AICC_Student_Name, which Lectora will auto-populate from the LMS, instead of asking the learner to type it in.

    If you’re not publishing to an LMS, you can try <span class=”token tag”><span class=”token punctuation”><</span>input</span> <span class=”token attr-name”>name</span><span class=”token attr-value”><span class=”token punctuation”>=</span><span class=”token punctuation”>”</span>q<span class=”token punctuation”>”</span></span> <span class=”token attr-name”>type</span><span class=”token attr-value”><span class=”token punctuation”>=</span><span class=”token punctuation”>”</span>text<span class=”token punctuation”>”</span></span> <span class=”token attr-name”>autocomplete</span><span class=”token attr-value”><span class=”token punctuation”>=</span><span class=”token punctuation”>”</span>off<span class=”token punctuation”>”</span></span><span class=”token punctuation”>/> </span><span class=”token punctuation”>in CSS, or in javascript:</span>

    someForm.setAttribute( "autocomplete", "off" );
    someFormElm.setAttribute( "autocomplete", "off" );

    They may not work in all browsers, but that’s the best I’ve got.

    This post has received 1 vote up.
    #384610 Score: 0
    Profile photo of Cam Phillips
    Cam Phillips
    Member
    beginner
    intermediate
    friend finder
    wise owl
    curious george
    contributor
    19 pts
    @_

    Hi Stan,

    These ones are being deployed to both a HTML website and LMS – I’ve set the courses up to:

    * Check if AICC_Student_Name is ‘null’ or contains data
    * If ‘null’ (as in HTML version) direct learners to name entry page and generate certificate
    * If non ‘null’, skip the name entry, split and reorder first/last name from AICC_Student_Name and drop this straight into certificate

    This way I can just keep one version of the course and not have to replicate any changes across multiple files!

    I’ll give that Javascript a go and see if it works, thanks for the suggestion!

    #384844 Score: 0
    Profile photo of CarlFink
    CarlFink
    Member
    beginner
    intermediate
    contributor
    LUC16 Attendee
    wise owl
    curious george
    advanced
    22 pts
    @CarlFink

    Can you turn off autocomplete using JavaScript?

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.