mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-02-22 02:46:30 +00:00
* initial commit for system information bug report data * add javascript to copy to clipboard * add javascript to copy to clipboard * Update copy_to_clipboard.js * Update system.php * Update app_languages.php Add other languages * move function file to resources/functions directory * use the array returned from system_information function * Update app_languages.php * update path locations * remove require files * Merge origin/create_json_page_for_bug_report into create_json_page_for_bug_report
13 lines
374 B
JavaScript
13 lines
374 B
JavaScript
function copy_to_clipboard() {
|
|
const span_id = document.getElementById("system_information");
|
|
const text_to_copy = span_id.innerText;
|
|
|
|
navigator.clipboard.writeText(text_to_copy)
|
|
.then(function() {
|
|
console.log('Text successfully copied to clipboard');
|
|
})
|
|
.catch(function(err) {
|
|
console.error('Unable to copy text to clipboard', err);
|
|
});
|
|
}
|