forked from Automattic/liveblog
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathliveblog-loop.php
40 lines (29 loc) · 1.19 KB
/
liveblog-loop.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php
$show_archived_message = $template_variables['show_archived_message'] ?? '';
$entries = $template_variables['show_archived_message'] ?? [];
?>
<?php if ( $show_archived_message ) : ?>
<div class="liveblog-archived-message">
<?php
// translators: 1: edit post url
echo wp_kses_post( sprintf( __( '<strong>This liveblog is archived.</strong> If you need to publish new updates or edit or delete the old ones, you need to <a href="%s">enable it first</a>.', 'liveblog' ), get_edit_post_link() . '#liveblog' ) );
?>
</div>
<?php endif; ?>
<div id="liveblog-entries">
<?php foreach ( (array) $entries as $entry ) : ?>
<?php echo wp_kses_post( $entry->render() ); ?>
<?php endforeach; ?>
<?php if ( Liveblog_Lazyloader::is_enabled() ) : ?>
<button class="liveblog-load-more" data-set-index="0"><?php esc_html_e( 'Load more entries…', 'liveblog' ); ?></button>
<?php endif; ?>
<div id="liveblog-fixed-nag" class="liveblog-fixed-bar">
<a href="#">
</a>
</div>
<?php if ( Liveblog_Socketio_Loader::is_enabled() ) : ?>
<div id="liveblog-socketio-error-container" class="liveblog-fixed-bar">
<p id="liveblog-socketio-error"></p>
</div>
<?php endif; ?>
</div>