d7eef400 by Jeff Balicki

ee

1 parent 019fac03
......@@ -28,7 +28,7 @@ function getInputFormValues($validation, $name) {
</div>
<?php endif; ?>
<form enctype="multipart/form-data" method="post" action="/wp-admin/admin.php?page=notifications-create-new">
<form enctype="multipart/form-data" method="post" id="notifications-create-new" action="/wp-admin/admin.php?page=notifications-create-new">
<input type="hidden" name="_POSTED_" value="yes"/>
......@@ -291,6 +291,40 @@ function getInputFormValues($validation, $name) {
<script>
jQuery(document).ready(function ($) {
var codeCleaned = false;
$("#notifications-create-new").on("submit", function(e){
if (!codeCleaned) {
e.preventDefault();
$('#fr_html_ifr').contents().find('td:last-child').each(function(){
$(this).addClass('tdlast-child');
});
$('#fr_html_ifr').contents().find('tr:last-child').each(function(){
$(this).addClass('trlast-child');
});
$('#en_html_ifr').contents().find('td:last-child').each(function(){
$(this).addClass('tdlast-child');
});
$('#en_html_ifr').contents().find('tr:last-child').each(function(){
$(this).addClass('trlast-child');
});
codeCleaned = true;
// $(this).trigger('submit');
}
});
$('#tabs').tabs();
// Update system message type clone when changing the message type
......@@ -372,6 +406,7 @@ function getInputFormValues($validation, $name) {
jQuery('.trigger-extended').show();
}else if (type == "newsletter") {
jQuery("#tabs").append('<input type="hidden" id="email_style" name="email_style" class="wide-input-field" />');
jQuery("#email_style").val('newsletter');
jQuery('.scheduled-extended').show();
......