#9254 load password with ajax
This commit is contained in:
parent
d14bcfe616
commit
795308367f
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
|
||||
$token_name = get_parameter('token_name', 0);
|
||||
$no_boolean = (bool) get_parameter('no_boolean', 0);
|
||||
|
||||
$value_token = db_get_value(
|
||||
'value',
|
||||
|
@ -9,4 +10,8 @@ $value_token = db_get_value(
|
|||
$token_name
|
||||
);
|
||||
|
||||
echo (bool) $value_token;
|
||||
if ($no_boolean === true) {
|
||||
echo json_encode(io_safe_output($value_token));
|
||||
} else {
|
||||
echo (bool) $value_token;
|
||||
}
|
||||
|
|
|
@ -2176,3 +2176,19 @@ $.fn.filterByText = function(textbox) {
|
|||
});
|
||||
});
|
||||
};
|
||||
|
||||
function loadPasswordConfig(id, value) {
|
||||
$.ajax({
|
||||
url: "ajax.php",
|
||||
data: {
|
||||
page: "include/ajax/config.ajax",
|
||||
token_name: `${value}`,
|
||||
no_boolean: 1
|
||||
},
|
||||
type: "GET",
|
||||
dataType: "json",
|
||||
success: function(data) {
|
||||
$(`#${id}`).val(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue