Skip to content

Commit

Permalink
Fix page load timer + add missing template
Browse files Browse the repository at this point in the history
Fix page load timer + add missing forum redirect template
  • Loading branch information
samerton committed May 31, 2018
1 parent a0e3411 commit bb7d68e
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 11 deletions.
2 changes: 1 addition & 1 deletion upload/custom/templates/Nextyle/forum/forum_index.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
<a href="{$subforum->last_post->profile}"><img
alt="{$subforum->last_post->profile}"
style="height:40px; width:40px;"
class="img-centre rounded"
class="img-centre img-rounded"
src="{$subforum->last_post->avatar}"/></a>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{include file='navbar.tpl'}

<div class="container">
<div class="card">
<div class="card-block">
{$CONFIRM_REDIRECT}
<hr />
<div class="btn-group btn-group-lg" role="group" aria-label="...">
<a href="{$FORUM_INDEX}" class="btn btn-secondary">{$NO}</a>
<a href="{$REDIRECT_URL}" target="_blank" rel="noopener nofollow" class="btn btn-{$NEXTYLE_COLOR}">{$YES}</a>
</div>
</div>
</div>
</div>

{include file='footer.tpl'}
2 changes: 1 addition & 1 deletion upload/custom/templates/Nextyle/forum/view_topic.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@
<small>{$reply.user_title}</small>
{/if}
<hr/>
{$reply.user_posts_count} {$POSTS}<br/>
{$reply.user_posts_count}<br/>
<hr/>
</center>
{if count($reply.fields)}
Expand Down
17 changes: 8 additions & 9 deletions upload/custom/templates/Nextyle/template.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,18 @@
}

// Page load time
$page_load = microtime(true) - $start;
if(isset($page_loading) && $page_loading == '1'){
$js = '
<script type="text/javascript">
var timer = \'' . str_replace('{x}', round($page_load, 3), $language->get('general', 'page_loaded_in')) . '\';
$(\'#page_load_tooltip\').attr(\'title\', timer).tooltip();
</script>';
} else $js = '';
if(isset($page_loading) && $page_loading == '1') {
$page_load_js = '
<script type="text/javascript">
var timer = \'' . $language->get('general', 'page_loaded_in') . '\';
$(\'#page_load_tooltip\').attr(\'title\', timer).tooltip();
</script>';
}

// <style> tags
$style = array('<style>.nextyle-headtop {background: url(\'' . $nextyle_bg . '\') no-repeat center top;}</style>');

$js.= '
$js = '
<script type="text/javascript">
$(function () {
$(\'[data-toggle="tooltip"]\').tooltip()
Expand Down

0 comments on commit bb7d68e

Please sign in to comment.