Index: branches/unlabeled/unlabeled-1.3.2/core/admin_templates/incs/footer.tpl
===================================================================
diff -u -N -r7701 -r7725
--- branches/unlabeled/unlabeled-1.3.2/core/admin_templates/incs/footer.tpl (.../footer.tpl) (revision 7701)
+++ branches/unlabeled/unlabeled-1.3.2/core/admin_templates/incs/footer.tpl (.../footer.tpl) (revision 7725)
@@ -3,58 +3,13 @@
var o = '';
var el = document.getElementById('scroll_container');
if (el) {
- document.body.style.overflow = 'hidden';
document.body.style.height = '100%';
+ document.body.style.overflow = 'hidden';
document.body.scroll = 'no'
- o += '
';
- o += el.innerHTML + '
';
- el.innerHTML = o;
- execJS(el)
- MakeHeight100();
- addEvent(window, 'resize', function() {MakeHeight100()})
- }
- function MakeHeight100(id)
- {
- if (!id) id = 'scroll_container';
- AdjustTextAreas(true); // reseting textareas to minimal size
- var el = document.getElementById(id);
- var h = (document.all ? window.document.body.offsetHeight : window.innerHeight) - el.offsetTop + 'px';
- var w = (document.all ? window.document.body.offsetWidth : window.innerWidth) - el.offsetLeft + 'px';
-// alert('h: '+h)
- el.style.height = h;
-// el.style.width=w;
- AdjustTextAreas(); // adjusting textarea height
+ addLoadEvent(function() {Form.Init('scroll_container')});
}
- function AdjustTextAreas(reset)
- {
- var tmp;
- var sizes = new Array();
- if (isset(textareas100)) {
- // we need separate cycle to get heights, because if we set the height in the same cycle
- // it will recursively affect heights of other textareas
- for (var i in textareas100) {
- tmp = document.getElementById(textareas100[i]);
- sizes[tmp.name] = tmp.parentNode.offsetHeight;
- }
- for (var i in textareas100) {
- tmp = document.getElementById(textareas100[i]);
- tmp.style.height = reset ? '70px' : (sizes[tmp.name] - 18) + 'px';
- }
- }
- }
-
- if (isset(first_error)) {
- for (var i in first_error) {
- if (first_error[i] != false) {
-// show_form_error(i, first_error[i][0]);
- document.getElementById(first_error[i][1]).focus();
-// alert('focused on '+first_error[i][1])
- }
- }
- }
-