Browse Source

Update ajax.js

Volodymyr Tkach 2 years ago
parent
commit
cc5c3a07b1
1 changed files with 2 additions and 2 deletions
  1. 2 2
      js/ajax.js

+ 2 - 2
js/ajax.js

@@ -115,9 +115,9 @@ ajax.processTag = function(tag) {
 	var func = tag.getAttribute('data-ajax-func');
 	var field = tag.getAttribute('data-ajax-field');
 	var delay = tag.getAttribute('data-ajax-delay');
-	if(get && get != null && func && func != null) {
+	if((get && get != null) && ((func && func != null) || (field && field != null))) {
 		if(delay == null) {
-			ajax.loadTag(tag, get, func);
+			ajax.loadTag(tag, get, func, field);
 		} else {
 			setTimeout(function() {
 				ajax.loadTag(tag, get, func, field);