info_box (Entry Nr. 447, by user 1 | edit) |
|
|
| /**
* displays a lightbox with custom html contents
**/
function ge_infoBox(text)
{
bg = document.createElement("div");
bg.id = 'ge_modal_bg';
bg.style.position = 'absolute';
bg.style.top = 0;
bg.style.width = '100%';
bg.style.height = '100%';
bg.style.opacity = .75;
bg.style.backgroundColor = '#808080';
bg.style.filter = 'alpha(opacity=75)'; //filter for ie6 transparency issue
box = document.createElement("div");
box.id = 'ge_modal_box';
box.style.position = 'absolute';
box.style.top = '40%';
box.style.left = '35%';
box.style.width = '30%';
box.style.backgroundColor = '#ffffff';
box.style.border = '1px solid #000000';
box.style.padding = '10px';
box.innerHTML = text;
//append to end of body
document.body.appendChild(bg);
document.body.appendChild(box);
}
/**
* closes a box created with ge_infoBox()
**/
function ge_modal_info_close()
{
document.body.removeChild(document.getElementById('ge_modal_bg'));
document.body.removeChild(document.getElementById('ge_modal_box'));
}
|
|
|
Create a new entry at this position
|
|
|