ILIAS
release_5-2 Revision v5.2.25-18-g3f80b828510
◀ ilDoc Overview
class.ilLightboxGUI.php
Go to the documentation of this file.
1
<?
php
2
3
/* Copyright (c) 1998-2011 ILIAS open source, Extended GPL, see docs/LICENSE */
4
12
class
ilLightboxGUI
13
{
14
protected
$id
=
""
;
15
22
function
__construct
($a_id)
23
{
24
$this->
setId
($a_id);
25
}
26
32
function
setId
($a_val)
33
{
34
$this->
id
= $a_val;
35
}
36
42
function
getId
()
43
{
44
return
$this->id
;
45
}
46
52
function
setWidth
($a_val)
53
{
54
$this->width = $a_val;
55
}
56
62
function
getWidth
()
63
{
64
return
$this->width;
65
}
66
70
static
function
getLocalLightboxJsPath
()
71
{
72
return
"./Services/UIComponent/Lightbox/js/Lightbox.js"
;
73
}
74
78
public
function
addLightbox
($a_tpl = null)
79
{
80
global
$tpl
;
81
82
if
($a_tpl == null)
83
{
84
$a_tpl =
$tpl
;
85
}
86
87
$a_tpl->addJavaScript(self::getLocalLightboxJsPath());
88
$a_tpl->addLightbox($this->
getHTML
(), $this->
getId
());
89
}
90
97
function
getHTML
()
98
{
99
$tpl
=
new
ilTemplate
(
"tpl.lightbox.html"
,
true
,
true
,
"Services/UIComponent/Lightbox"
);
100
$tpl
->setVariable(
"LIGHTBOX_CONTENT"
,
""
);
101
$tpl
->setVariable(
"ID"
, $this->
getId
());
102
if
($this->
getWidth
() !=
""
)
103
{
104
$tpl
->setVariable(
"WIDTH"
,
"width: "
.$this->
getWidth
().
";"
);
105
}
106
return
$tpl
->get();
107
}
108
109
}
110
111
?>
ilLightboxGUI\getWidth
getWidth()
Get width.
Definition:
class.ilLightboxGUI.php:62
ilLightboxGUI\getHTML
getHTML()
Get HTML.
Definition:
class.ilLightboxGUI.php:97
ilLightboxGUI
Lighbox handling.
Definition:
class.ilLightboxGUI.php:12
ilLightboxGUI\setWidth
setWidth($a_val)
Set width.
Definition:
class.ilLightboxGUI.php:52
ilLightboxGUI\setId
setId($a_val)
Set Id.
Definition:
class.ilLightboxGUI.php:32
$tpl
global $tpl
Definition:
ilias.php:8
ilLightboxGUI\getLocalLightboxJsPath
static getLocalLightboxJsPath()
Get local path of jQuery file.
Definition:
class.ilLightboxGUI.php:70
ilTemplate
special template class to simplify handling of ITX/PEAR
Definition:
class.ilTemplate.php:13
ilLightboxGUI\getId
getId()
Get Id.
Definition:
class.ilLightboxGUI.php:42
ilLightboxGUI\__construct
__construct($a_id)
Constructor.
Definition:
class.ilLightboxGUI.php:22
php
ilLightboxGUI\$id
$id
Definition:
class.ilLightboxGUI.php:14
ilLightboxGUI\addLightbox
addLightbox($a_tpl=null)
Init lightbox.
Definition:
class.ilLightboxGUI.php:78
Services
UIComponent
Lightbox
classes
class.ilLightboxGUI.php
Generated on Fri Jan 24 2025 19:01:16 for ILIAS by
1.8.13 (using
Doxyfile
)