Collections functions
Encryption functions
General functions
Render functions
Theme permission functions
Video functions
Resource functions

render_share_password_question()

Parameters

ColumnTypeDefaultDescription
$blank true

Location

include/render_functions.php lines 5206 to 5254

Definition

 
function render_share_password_question($blank=true)
    {
    global 
$lang;
    
?>
    <div class="Question">
    <label for="sharepassword"> echo htmlspecialchars($lang["share-set-password"]) ?></label>
    <input type="password" id="sharepassword" name="sharepassword" maxlength="40" class="stdwidth" value=" echo $blank "" $lang["password_unchanged"]; ?>">
    <span class="fa fa-fw fa-eye infield-icon" onclick="togglePassword('sharepassword');"></span>
    <script>

    function togglePassword(pwdelement)
        {
        input = jQuery('#' + pwdelement);
        if (input.attr("type") == "password")
            {
            input.attr("type", "text");
            }
        else
            {
            input.attr("type", "password");
            }
        }
    var passInput="";
    var passState="(unchanged)";
    var passHistory="";
    function pclick(id) 
        {
        // Set to password mode
        document.getElementById(id).type="password";
        document.getElementById(id).value=passState;
        document.getElementById(id).select();
        }
    function pblur(id) 
        {
        // Copy keyed input other than bracketed placeholders to hidden password
        passInput = document.getElementById(id).value;
        if(passInput!="(unchanged)" && passInput!="(changed)") 
            {
            document.getElementById("sharepassword").value=passInput; 
            passState="(changed)";
            }
        // Return to text mode showing the appropriate bracketed placeholder
        document.getElementById(id).value=passState;
        document.getElementById(id).type="text";
        }
    </script>
    </div>
    
    
}

This article was last updated 28th February 2021 15:05 Europe/London time based on the source file dated 22nd February 2021 17:55 Europe/London time.