Skip to content

Commit

Permalink
Fixing IE 7 button problems
Browse files Browse the repository at this point in the history
  • Loading branch information
rogerly committed Oct 4, 2011
1 parent 2ec80dc commit d1d49ae
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion templates/applicant/account/profile.html
Expand Up @@ -94,7 +94,7 @@
<div class="fieldWrapper">
{{ form.password1.label_tag }} &bull;&bull;&bull;&bull;
</div>
<div class="right"><button type="button">Edit</button></div>
<div class="right"><button type="button" class="no-submit">Edit</button></div>
<div class="clearing"></div>
</div>
<div id="account-details-form">
Expand Down
9 changes: 8 additions & 1 deletion templates/base.html
Expand Up @@ -17,9 +17,16 @@
<script type="text/javascript">
$(document).ready(function() {
$('a > button').click(function() {
location.href = $(this).parent().attr('href');
location.href = $(this).parent().attr('href');
return false;
});

$('form button').click(function() {
if (!$(this).hasClass('no-submit')) {
$(this).closest('form').submit();
return false;
}
});
})
</script>
</head>
Expand Down
2 changes: 1 addition & 1 deletion templates/employer/account/profile.html
Expand Up @@ -98,7 +98,7 @@
<div class="fieldWrapper">
{{ form.password1.label_tag }} &bull;&bull;&bull;&bull;&bull;
</div>
<div class="right"><button type="button">Edit</button></div>
<div class="right"><button type="button" class="no-submit">Edit</button></div>
<div class="clearing"></div>
</div>
<div id="account-details-form">
Expand Down

0 comments on commit d1d49ae

Please sign in to comment.