consentLink in IinitiateRecorder is not blue?

PennController for IBEX Forums Support consentLink in IinitiateRecorder is not blue?

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #7125
    Shereen_Potsdam
    Participant

    Hi Jeremy,
    I have an issue with the consentLink in my InitiateRecorder, I don’t know if it’s a language issue but when I run my experiment with the consentLink statement in English, the font is blue and becomes underlined when you run the cursor over it to indicate that the statement is clickable. But when I edit the link and replaced it with German instructions, the statement is in regular black font and does not underline when you run the cursor over it, which doesn’t make it look like a clickable link. Although the link works perfectly fine when you click it, I would still like it to be blue and underlined when you run the cursor over it. Below is the code I used in InitiateRecorder, please let me know if I am missing something!

    let replaceConsentMic = ()=>{
            let consentLink = $(".PennController-PennController a.Message-continue-link");
            if (consentLink.length > 0 && consentLink[0].innerHTML.match(/^By clicking this link I understand that I grant this experiment's script access to my recording device/))
                consentLink.html("Durch klicken erteile ich diesem Skript Zugriff auf mein Mikrofon");
            else
                window.requestAnimationFrame( replaceConsentMic );
    };

    Thank you in advance,
    Shereen

    #7126
    Jeremy
    Keymaster

    Hi Shereen,

    I am not sure why this happens, since the Message-continue-link class should apply the desired aesthetics. Try replacing consentLink.html with consentLink.text, in case some related HTML tags gets lost in the process

    Jeremy

    #7132
    Shereen_Potsdam
    Participant

    Hi Jeremy,

    Thank you for your reply, I tried that and it didn’t work. Then I figured out that it actually has to do with the way the text that precedes it within the the trial is written. The last line in the trial was written in the following way:

    <p> To continue, please click on the link below.

    (it was missing the closing </p> at the end).
    So when I added </p> at the end of the text, it worked perfectly fine 🙂

    Thank you as usual for your help,
    Shereen

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.