Correzione avviso di modifica input
This commit is contained in:
parent
fe2117f26b
commit
9351ddf79d
10
editor.php
10
editor.php
|
@ -472,19 +472,19 @@ if ($read_only || !empty($block_edit)) {
|
||||||
|
|
||||||
var content_was_modified = false;
|
var content_was_modified = false;
|
||||||
|
|
||||||
//controllo se digito qualche valore o cambio qualche select
|
// Controllo se digito qualche valore o cambio qualche select
|
||||||
$("input, textarea, select").bind("change paste keyup", function(event) {
|
$(".content input, .content textarea, .content select").bind("change paste keyup", function(event) {
|
||||||
if (event.keyCode >= 32) {
|
if (event.keyCode >= 32) {
|
||||||
content_was_modified = true;
|
content_was_modified = true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
$(".superselect, .superselectajax").on("change", function (e) {
|
$(".content .superselect, .content .superselectajax").on("change", function (e) {
|
||||||
content_was_modified = true;
|
content_was_modified = true;
|
||||||
});
|
});
|
||||||
|
|
||||||
//tolgo il controllo se sto salvando
|
// Tolgo il controllo se sto salvando
|
||||||
$(".btn-success, button[type=submit]").bind("click", function() {
|
$(".content .btn-success, .content button[type=submit]").bind("click", function() {
|
||||||
content_was_modified = false;
|
content_was_modified = false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -266,4 +266,5 @@ input("prezzo_qta").change(function () {
|
||||||
})
|
})
|
||||||
|
|
||||||
$(document).ready(cambioImpostazioni);
|
$(document).ready(cambioImpostazioni);
|
||||||
|
content_was_modified = false;
|
||||||
</script>';
|
</script>';
|
||||||
|
|
|
@ -84,4 +84,7 @@ echo '
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<script>$(document).ready(init);</script>';
|
<script>
|
||||||
|
$(document).ready(init);
|
||||||
|
content_was_modified = false;
|
||||||
|
</script>';
|
||||||
|
|
Loading…
Reference in New Issue