merging 10043 into the trunk

This commit is contained in:
tworrall 2012-09-07 17:10:04 +00:00
parent 0a72583712
commit 794602c22a

View file

@ -38,7 +38,13 @@
</td> </td>
</tr> </tr>
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() {
var source = "";
$('input#primaryAction').click(function() {
source = "submit";
});
$('form#editForm').submit(function() { $('form#editForm').submit(function() {
if (source == "submit") {
var str = $('input[name=URI]').val(); var str = $('input[name=URI]').val();
if ( str.indexOf('http://') >= 0 || str.indexOf('https://') >= 0 ) { if ( str.indexOf('http://') >= 0 || str.indexOf('https://') >= 0 ) {
return true; return true;
@ -46,7 +52,10 @@
else { else {
alert('The Namespace URI must begin with either http:// \n\n or https://'); alert('The Namespace URI must begin with either http:// \n\n or https://');
$('input[name=URI]').focus(); $('input[name=URI]').focus();
source = "";
return false; return false;
} }
}
}); });
});
</script> </script>