Javascript functions
This commit is contained in:
parent
a31f11d8c6
commit
d84d0065d5
|
@ -1,13 +1,4 @@
|
||||||
<script>
|
<?php defined('BLUDIT') or die('Bludit CMS.'); ?>
|
||||||
|
|
||||||
function copyToClipboard(elementId) {
|
|
||||||
var aux = document.createElement("input");
|
|
||||||
aux.setAttribute("value", document.getElementById(elementId).innerHTML);
|
|
||||||
document.body.appendChild(aux);
|
|
||||||
aux.select();
|
|
||||||
document.execCommand("copy");
|
|
||||||
document.body.removeChild(aux);
|
|
||||||
}
|
|
||||||
|
|
||||||
function sanitizeHTML(text) {
|
function sanitizeHTML(text) {
|
||||||
var map = {
|
var map = {
|
||||||
|
@ -45,5 +36,3 @@ function getCookie(name) {
|
||||||
function deleteCookie(name) {
|
function deleteCookie(name) {
|
||||||
document.cookie = name+'=; Max-Age=-999;';
|
document.cookie = name+'=; Max-Age=-999;';
|
||||||
}
|
}
|
||||||
|
|
||||||
</script>
|
|
||||||
|
|
Loading…
Reference in New Issue