mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-30 01:05:39 +02:00
2013-08-08 Koichiro Kikuchi <koichiro@rworks.jp>
* index.php: Fixed footer layout probrems: Now we can see the footer at the browser bottom when reducing the browser height. Also fixes the footer overlay probrem in some pages (e.g. "Modules in policy" page). git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@8647 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
1e95f6eb64
commit
8b705f701c
@ -1,3 +1,10 @@
|
|||||||
|
2013-08-08 Koichiro Kikuchi <koichiro@rworks.jp>
|
||||||
|
|
||||||
|
* index.php: Fixed footer layout probrems: Now we can see the
|
||||||
|
footer at the browser bottom when reducing the browser height.
|
||||||
|
Also fixes the footer overlay probrem in some pages (e.g.
|
||||||
|
"Modules in policy" page).
|
||||||
|
|
||||||
2013-08-08 Miguel de Dios <miguel.dedios@artica.es>
|
2013-08-08 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
* images/zoom_default.svg: tiny fixes make for Carla.
|
* images/zoom_default.svg: tiny fixes make for Carla.
|
||||||
|
@ -570,18 +570,34 @@ require('include/php_to_js_values.php');
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<script type="text/javascript" language="javascript">
|
<script type="text/javascript" language="javascript">
|
||||||
|
|
||||||
|
//Dynamically assign footer position and width.
|
||||||
//Initial load of page
|
//Initial load of page
|
||||||
$(document).ready(sizeContent);
|
$(document).ready(adjustFooter);
|
||||||
|
|
||||||
//Every resize of window
|
//Every resize of window
|
||||||
$(window).resize(sizeContent);
|
$(window).resize(adjustFooter);
|
||||||
|
|
||||||
|
//Every resize (height change) of div#container
|
||||||
|
container_height = $('#container').height();
|
||||||
|
$('#container').bind((window.opera ? 'DOMAttrModified' : 'DOMSubtreeModified'), function() {
|
||||||
|
if (container_height != $('#container').height()) {
|
||||||
|
container_height = $('#container').height();
|
||||||
|
adjustFooter();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
//Dynamically assign height
|
//Dynamically assign height
|
||||||
function sizeContent() {
|
function adjustFooter() {
|
||||||
var footposition_bottom = $('#foot').position().top + $("#foot").height();
|
// highest Y pos for #foot
|
||||||
|
var ulim = $('#container').position().top + $('#container').outerHeight(true);
|
||||||
|
// $(window).height() returns wrong value on Opera and Google Chrome.
|
||||||
|
var wh = $(window).height(); //document.documentElement.clientHeight;
|
||||||
|
var h = $('#foot').height();
|
||||||
|
var t = (ulim + $('#foot').outerHeight() > wh) ? ulim : wh - $('#foot').outerHeight();
|
||||||
|
|
||||||
if (footposition_bottom < $(window).height()) {
|
$('#foot').css({ position: "absolute", top: t, left: $('#foot').offset().left});
|
||||||
$('#container').css('height', $(window).height() - $("#foot").height() - 15 + 'px');
|
$('#foot').width($(window).width());
|
||||||
}
|
$('#foot').height(h);
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user