Switch from addLoadEvent to jQuery(document).ready. Fixes #6241 props azaozz.

git-svn-id: https://develop.svn.wordpress.org/trunk@7325 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Peter Westwood
2008-03-15 22:57:47 +00:00
parent 5a72522fb2
commit 2d7ba950bc
12 changed files with 26 additions and 41 deletions

View File

@@ -12,13 +12,6 @@ $form_extra = "' />\n<input type='hidden' name='comment_ID' value='" . $comment-
<input type="hidden" name="user_ID" value="<?php echo (int) $user_ID ?>" />
<input type="hidden" name="action" value='<?php echo $form_action . $form_extra ?>' />
<script type="text/javascript">
function focusit() { // focus on first input field
document.post.name.focus();
}
addLoadEvent(focusit);
</script>
<div id="poststuff">
<div class="submitbox" id="submitcomment">
@@ -108,3 +101,7 @@ echo "<a href='" . wp_nonce_url("comment.php?action=deletecomment&amp;c=$comment
</div>
</form>
<script type="text/javascript">
try{document.post.name.focus();}catch(e){}
</script>