| Server IP : 23.94.149.180 / Your IP : 216.73.216.147 Web Server : nginx/1.20.1 System : Linux deadrock 5.14.0-741.22.1.el9_9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Nov 12 15:18:14 UTC 2026 x86_64 User : apache ( 48) PHP Version : 8.6.0 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /files/webmaint/dseals/www/withgrace/blogcms/admin/javascript/ |
Upload File : |
/**
* BLOG:CMS - http://blogcms.com
* Copyright (C) 2003-2004 Radek HULAN
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
* (see nucleus/documentation/index.html#license for more info)
*
* This file contains functions to allow adding items from inside the weblog.
* Also contains code to avoid submitting form data twice.
*/
var amountOfFields = 1;
var editText = 'empty field (click to edit)';
function hideUnused() {
while (document.getElementById('textarea' + amountOfFields))
amountOfFields++;
amountOfFields--;
for (var i=1;i<=amountOfFields;i++) {
var el = document.getElementById('textarea' + i);
// hide textareas when empty, and add onclick event
// to make them visible again
if (el.value == '') {
el.style.display = 'none';
var tdEl = document.getElementById('td' + i);
var aHref = createElement('a');
aHref.href = '';
aHref.className = "expandLink";
aHref.id = "expandLink" + i;
aHref.onclick = new Function("return makeVisible("+i+")");
aHref.tabIndex = el.tabIndex;
aHref.title = editText;
aHref.appendChild(document.createTextNode(editText));
tdEl.appendChild(aHref);
}
}
}
function setTemplateEditText(newText) {
editText = newText;
}
function makeVisible(i) {
var textareaEl = document.getElementById('textarea' + i);
var expandEl = document.getElementById('expandLink' + i);
textareaEl.style.display = 'block';
expandEl.style.display = 'none';
textareaEl.focus();
return false;
}
window.onload = hideUnused;