ILIAS
release_6 Revision v6.24-5-g0c8bfefb3b8
◀ ilDoc Overview
Main Page
Related Pages
Modules
+
Namespaces
Namespace List
+
Namespace Members
+
All
$
_
a
b
c
d
e
f
g
h
i
j
l
m
p
s
t
w
+
Functions
_
a
b
c
f
g
h
i
s
t
w
+
Variables
$
c
d
e
f
g
h
j
l
m
p
s
t
+
Data Structures
Data Structures
Data Structure Index
Class Hierarchy
+
Data Fields
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Files
File List
+
Globals
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
+
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
+
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Modules
Pages
show_popover_with_async_loaded_content.php
Go to the documentation of this file.
1
<?php
2
function
show_popover_with_async_loaded_content
()
3
{
4
global
$DIC
;
5
$factory
= $DIC->ui()->factory();
6
$renderer = $DIC->ui()->renderer();
7
8
if
(isset(
$_GET
[
'renderPopoverAsync'
]) &&
$_GET
[
'renderPopoverAsync'
]) {
9
// This is the ajax request to load the content of the popover. During the ajax request,
10
// a loading spinner is presented to the user. Check the code below on how to construct the popover,
11
// e.g. using Popover::withAsyncContentUrl().
12
$content =
$factory
->legacy(
'This text is rendered async'
);
13
echo $renderer->render($content);
14
exit
();
15
}
16
17
$async_url =
$_SERVER
[
'REQUEST_URI'
] .
'&renderPopoverAsync=1'
;
18
$popover =
$factory
->popover()->standard(
$factory
->legacy(
''
))
19
->withTitle(
'Popover'
)
20
->withAsyncContentUrl($async_url);
21
$button =
$factory
->button()->standard(
'Show Popover'
,
'#'
)
22
->withOnClick($popover->getShowSignal());
23
24
return
$renderer->render([$popover, $button]);
25
}
exit
exit
Definition:
login.php:29
$_GET
$_GET["client_id"]
Definition:
cfg.phpunit.template.php:12
$_SERVER
$_SERVER['HTTP_HOST']
Definition:
raiseError.php:10
$DIC
$DIC
Definition:
xapitoken.php:46
show_popover_with_async_loaded_content
show_popover_with_async_loaded_content()
Definition:
show_popover_with_async_loaded_content.php:2
$factory
$factory
Definition:
metadata.php:58
src
UI
examples
Popover
Standard
show_popover_with_async_loaded_content.php
Generated on Fri Apr 25 2025 20:01:38 for ILIAS by
1.8.13 (using
Doxyfile
)