1
0

Replaces inline onclick handler for .status_timestamp.

Also moved reference to serendipity_editor.js before the closing
body element. This way, jQuery's $(document).ready() equals
$(window).load(), so we don't have to use that any longer.
This commit is contained in:
Matthias Mees
2013-05-31 18:10:16 +02:00
parent c0e8922500
commit 75d45f811f
3 changed files with 18 additions and 17 deletions

View File

@ -129,7 +129,7 @@
<div class="entry_info clearfix">
<span class="status_timestamp">
{$entry.timestamp|@formatTime:"{$CONST.DATE_FORMAT_SHORT}"}{if $entry.timestamp <= ($entry.last_modified - 1800)} <a class="icon_link" href="#" title="{$CONST.LAST_UPDATED}: {$entry.last_modified|@formatTime:"{$CONST.DATE_FORMAT_SHORT}"}" onclick="alert(this.title)"><span class="icon-info-circle"></span><span class="visuallyhidden"> {$CONST.LAST_UPDATED}</span></a>{/if}
{$entry.timestamp|@formatTime:"{$CONST.DATE_FORMAT_SHORT}"}{if $entry.timestamp <= ($entry.last_modified - 1800)} <a class="icon_link" href="#" title="{$CONST.LAST_UPDATED}: {$entry.last_modified|@formatTime:"{$CONST.DATE_FORMAT_SHORT}"}"><span class="icon-info-circle"></span><span class="visuallyhidden"> {$CONST.LAST_UPDATED}</span></a>{/if}
</span>
<span class="entry_meta">{$CONST.POSTED_BY} {$entry.author|escape}

View File

@ -10,10 +10,7 @@
<meta name="viewport" content="width=device-width">
<link rel="stylesheet" href="{$admin_vars.css_file}">
<script src="{serendipity_getFile file='admin/js/modernizr-2.6.2.min.js'}"></script>
{if $admin_vars.admin_installed}
{serendipity_hookPlugin hook="backend_header" hookAll="true"}
{/if}
<script src="{serendipity_getFile file='admin/serendipity_editor.js'}"></script>
{if $admin_vars.admin_installed}{serendipity_hookPlugin hook="backend_header" hookAll="true"}{/if}
</head>
<body id="serendipity_admin_page">
{if NOT $admin_vars.no_banner}
@ -182,5 +179,6 @@
<p>{$admin_vars.version_info}</p>
</footer>
{/if}
<script src="{serendipity_getFile file='admin/serendipity_editor.js'}"></script>
</body>
</html>

View File

@ -666,18 +666,21 @@ function highlightComment(id, checkvalue) {
footer: '#meta'
});
// Wait until content including images is loaded
$(window).load(function() {
// Fire WYSIWYG editor(s)
spawn();
// Fire WYSIWYG editor(s)
spawn();
// Equal Heights
var $eqHeights = $('body').has('.equal_heights');
if($eqHeights.size() > 0) {
$('.equal_heights').syncHeight({
updateOnResize: true
});
}
// Click events
$('.status_timestamp > a').click(function(e) {
alert($(this).attr('title'));
e.preventDefault();
});
// Equal Heights
var $eqHeights = $('body').has('.equal_heights');
if($eqHeights.size() > 0) {
$('.equal_heights').syncHeight({
updateOnResize: true
});
}
})(jQuery);