diff --git a/app/webroot/js/dreamjob.js b/app/webroot/js/dreamjob.js index b91b6c7..2925ca8 100755 --- a/app/webroot/js/dreamjob.js +++ b/app/webroot/js/dreamjob.js @@ -28,6 +28,9 @@ var global_load = null; $("#popup .modal-footer").html($("#container div.box.2modal .modal-footer", data).html()); $("#popup .modal-body .modal-footer").remove(); $("#popup .modal-content").attr("action",$(".2modal form.modal-body",data).attr("action")); + $("#popup .modal-content").attr("enctype",$(".2modal form.modal-body[enctype]",data).attr("enctype")); + $("#popup .modal-content").attr("method",$(".2modal form.modal-body[method]",data).attr("method")); + event("#popup"); }, error: function(data) { }}); }); @@ -67,7 +70,8 @@ var global_load = null; }); }); - $(where + " form").submit(function(e) { + $(where + " form").submit(function(e) { + $("#popup").modal('hide'); if ($(this).attr('enctype') != 'multipart/form-data') { stopLoad(e); if ($(this).hasClass('tableForm')) { @@ -98,8 +102,9 @@ var global_load = null; $(this).attr('target', 'fileUpload'); $(":input[ name *= '_wysihtml5_mod' ]", this).remove(); $(this).submit(function() { - stopLoad(evt); + //stopLoad(evt); frame = $('#fileUpload').load(function() { + console.log("aha"); setContent($('#fileUpload').contents().find('html').html()); $('#fileUpload').unbind('load'); setTimeout(function() {